Re: Variable length arrays in debugger
Re: Variable length arrays in debugger
- Subject: Re: Variable length arrays in debugger
- From: Tverdokhleb Andrey <email@hidden>
- Date: Wed, 1 Oct 2008 11:27:14 -0700
It's allowed in C99. My code is in Objective-C though and it
definitely compiles and works just fine.
http://developer.apple.com/documentation/DeveloperTools/gcc-4.2.1/gcc/Variable-Length.html
Andrey
On Oct 1, 2008, at 11:16 , Howard Moon wrote:
I've noticed that debugger in Xcode 3.1.1 always shows variable
length arrays as "out of scope". If I change it to constant size
array it works as it supposed to.
I'm talking about this kind of things:
int size;
....
int array[size];
I'm ready to file a bug, but would like to figure before if I'm not
alone in this or may be there is some option needs to be enabled in
compiler (couldn't find anything though).
Is that an extension allowed in GCC? According to the C++ Standard,
arrays must have a compile-time constant size. Perhaps the Xcode
debugger assumes that rule to be the case, even if the compiler has
allowed it to compile?
-Howard
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
@gmail.com
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden