• 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
uint64_t and NSNumber
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

uint64_t and NSNumber


  • Subject: uint64_t and NSNumber
  • From: Adam Thorsen <email@hidden>
  • Date: Sun, 8 Jun 2008 20:40:49 -0700

I'm trying to store a uint64_t in an NSNumber object, but when I try to retrieve the value of the object, I get 0.


- (void)updateLastEventId:(uint64_t *) eventId
{
printf("eventId %llu \n", eventId);
//This results in something like:
lastEventId = [NSNumber numberWithUnsignedLongLong:(uint64_t *)eventId];
printf("retrieved eventId %llu \n", [lastEventId unsignedLongLongValue]);
}



The result of this is something like:

eventId 72915006949163008
retrieved eventId 0

Does someone know how to do this properly? I've looked up the typedef statement for uint64_t and it is:
typedef unsigned long long uint64_t;


Thanks,
-Adam
_______________________________________________

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: uint64_t and NSNumber
      • From: Andrew Farmer <email@hidden>
  • Prev by Date: Re: Using NSTrackingArea on overlay child windows
  • Next by Date: Re: uint64_t and NSNumber
  • Previous by thread: Re: symbol(s) not found
  • Next by thread: Re: uint64_t and NSNumber
  • Index(es):
    • Date
    • Thread