• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Corrupted NSMutableString
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Corrupted NSMutableString


  • Subject: Re: Corrupted NSMutableString
  • From: Cameron Hayne <email@hidden>
  • Date: Sat, 02 Aug 2003 02:24:48 -0400

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.

  • Follow-Ups:
    • Re: Corrupted NSMutableString
      • From: Matthew <email@hidden>
References: 
 >Re: Corrupted NSMutableString (From: Shawn Erickson <email@hidden>)

  • Prev by Date: NSFont in TextViews
  • Next by Date: Optimizing for code size
  • Previous by thread: Re: Corrupted NSMutableString
  • Next by thread: Re: Corrupted NSMutableString
  • Index(es):
    • Date
    • Thread