Re: return a string
- From: Keith Thompson <kst-u@xxxxxxx>
- Date: Fri, 29 Apr 2005 23:56:05 GMT
Alan Balmer <albalmer@xxxxxxx> writes:
> On 29 Apr 2005 14:04:10 -0700, underscore0x5f@xxxxxxxxx (Nascimento)
> wrote:
[...]
>>{
>> int i;
>> char tralha[num];
>
> You can't declare a variable size array.
Yes you can, if you have a C99 compiler or a pre-C99 compiler that
supports the feature. (The form of the diagnostics implies that he's
probably using gcc, which does support VLAs.)
I covered the portability issues in my previous followup.
--
Keith Thompson (The_Other_Keith) kst-u@xxxxxxx <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.
.
- References:
- Re: return a string
- From: Alan Balmer
- Re: return a string
- Prev by Date: Re: return a string
- Next by Date: Re: How is strlen implemented?
- Previous by thread: Re: return a string
- Next by thread: Re: return a string
- Index(es):
Relevant Pages
|