• 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: Using #define a good way for String constants, like enums for NSIntegers?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using #define a good way for String constants, like enums for NSIntegers?


  • Subject: Re: Using #define a good way for String constants, like enums for NSIntegers?
  • From: Chris Hanson <email@hidden>
  • Date: Tue, 09 Aug 2011 10:51:12 -0700

On Aug 9, 2011, at 10:10 AM, Gregory Weston wrote:

> I'm still generally in favor of named constants over pre-processor substitution. Gives you types and no worry about parentheses.

You can also use the global constant in the debugger (including in command completion) because it has a symbol it can look up.  That helps cut down on typos when investigating bugs.

  -- Chris

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Re: Using #define a good way for String constants, like enums for NSIntegers? (From: Gregory Weston <email@hidden>)

  • Prev by Date: Re: Using #define a good way for String constants, like enums for NSIntegers?
  • Next by Date: Re: Lingering windows
  • Previous by thread: Re: Using #define a good way for String constants, like enums for NSIntegers?
  • Next by thread: Re: Using #define a good way for String constants, like enums for NSIntegers?
  • Index(es):
    • Date
    • Thread