Re: Corrupted NSMutableString
Re: Corrupted NSMutableString
- Subject: Re: Corrupted NSMutableString
- From: Matthew <email@hidden>
- Date: Sat, 2 Aug 2003 06:52:45 -0700 (PDT)
Shawn & Cameron,
Thanks! As it turns out, I just converted these arrays to
NSMutableArrays of NSNumbers... It didn't help with the orginal
problem, but the code looks cleaner. ;-)
Thanks again!
Matthew
--- Cameron Hayne <email@hidden> wrote:
>
On 1/8/03 11:49 PM, "Shawn Erickson" <email@hidden> wrote:
>
>
>
>
> On Friday, August 1, 2003, at 06:38 PM, Cameron Hayne wrote:
>
>
>
>> On 28/7/03 4:08 PM, "Matthew" <email@hidden> wrote:
>
>>> short int * zeroCalibrations[*numOfChannels];
>
>>> short int * gainCalibrations[*numOfChannels];
>
>>> short int trial[*numOfChannels];
>
>>
>
>> I know this isn't what you are asking about - but what are those
>
arrays
>
>> doing getting declared with what appears to be a variable?
>
>> This is not valid C code (or Obj-C code) - you must declare arrays
>
with
>
>> sizes that are known at compile time. I recall that gcc might
>
allow
>
>> this
>
>> sort of thing - but it should not.
>
>> If you want dynamically sized arrays, you should allocate them. Or
>
use
>
>> NSArray, etc.
>
>
>
> No the doing the above is valid in C (as of C99). You can do it if
>
you
>
> want.
>
>
>
> -Shawn
>
>
>
>
Thanks for the correction - I hadn't realized this was part of C99.
>
>
--
>
Cameron Hayne (email@hidden)
>
Hayne of Tintagel
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.