• 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: NSInteger
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSInteger


  • Subject: Re: NSInteger
  • From: Nick Zitzmann <email@hidden>
  • Date: Wed, 3 Sep 2008 09:26:15 -0600


On Sep 3, 2008, at 8:58 AM, D.K. Johnston wrote:

I'm a bit puzzled by the new NSInteger type. Should I be using this now instead of int? (I'm just as puzzled by NSUInteger, of course.)


Yes! Otherwise you'll run into problems if you try to compile your application for 64-bit architectures. For example, if your code compares a returned integer to NSNotFound, the value of NSNotFound changed in 64-bit and is a number that is too large to fit into a 32- bit space, so the comparison will not work correctly, and you'll experience some breakage.

Nick Zitzmann
<http://www.chronosnet.com/>




_______________________________________________

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: 
 >NSInteger (From: "D.K. Johnston" <email@hidden>)

  • Prev by Date: Re: Font Color In CTLineDraw?
  • Next by Date: Re: utf8 to NSString crasher
  • Previous by thread: Re: NSInteger
  • Next by thread: NSTextView's scroller problem when scaling
  • Index(es):
    • Date
    • Thread