• 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/NSUInteger Considerations (64 bit)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSInteger/NSUInteger Considerations (64 bit)


  • Subject: Re: NSInteger/NSUInteger Considerations (64 bit)
  • From: Roland King <email@hidden>
  • Date: Fri, 28 Mar 2014 06:34:21 +0800

On 28 Mar, 2014, at 3:07 am, Dave <email@hidden> wrote:

>
> Yeah, well I want to be able to fit into the Cocoa Patterns, that’s why I posed the question in the first place…….
>
> This leads me to another question, if I am doing a lot of arithmetic on these numbers, what is the best type/fastest, native or NSInteger?

no difference, NSInteger, NSUInteger are just typedefs for underlying integral types, just they are typedefs to underlying types which change in different versions of the OS, and will change again when 128bit OSes arrive.


>
> I’ve defined my own set of file types, based on int32_t and friends and have made each property definition follow this type. If it’s noticible faster using NSInteger for arithmetic, then I was planning of moving the native type properties to iVar’s and making the Properties NSInteger's, I’d then write getters to return the value as an NSInteger rather than the native type.
>
> Cheers
> Dave
>
>
> _______________________________________________
>
> 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


_______________________________________________

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


  • Follow-Ups:
    • Re: NSInteger/NSUInteger Considerations (64 bit)
      • From: Jens Alfke <email@hidden>
References: 
 >NSInteger/NSUInteger Considerations (64 bit) (From: Dave <email@hidden>)
 >Re: NSInteger/NSUInteger Considerations (64 bit) (From: Jens Alfke <email@hidden>)
 >Re: NSInteger/NSUInteger Considerations (64 bit) (From: Chris Hanson <email@hidden>)
 >Re: NSInteger/NSUInteger Considerations (64 bit) (From: Dave <email@hidden>)

  • Prev by Date: Re: SplitView autolayout + autosave = proportionally resized views
  • Next by Date: Re: SplitView autolayout + autosave = proportionally resized views
  • Previous by thread: Re: NSInteger/NSUInteger Considerations (64 bit)
  • Next by thread: Re: NSInteger/NSUInteger Considerations (64 bit)
  • Index(es):
    • Date
    • Thread