Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > 64 bit integers

64 bit integers
Thread Tools
Professional Poster
Join Date: Jul 2001
Location: Dis
Status: Offline
Reply With Quote
Jul 22, 2002, 05:21 PM
 
Is there any way I can get 64 bit integers? I want to write a custom float composed of three 64 bit integers (the number will be (x ± y)×10^z [don't know of this html symbol will work]). In short, I want to implement a custom number type, but I really want the extra precision afforded by 64 bit integers. I've tried querying a sizeof(long int), and the system returns 4 bytes (same as sizeof(int))! Am I going to have to implement another custom data type comprised of two regular ints to get the precision I want?

It just seems like such a hassle, and it doesn't make sense. Shouldn't a long int be 64 bits (just like a long double should be 128)?

BlackGriffen
I do not feel obliged to believe that the same God who has endowed us with sense, reason, and intellect has intended us to forgo their use. -Galileo Galilei, physicist and astronomer (1564-1642)
     
Clinically Insane
Join Date: Oct 2001
Location: San Diego, CA, USA
Status: Offline
Reply With Quote
Jul 22, 2002, 08:22 PM
 
This looks like what you're looking for: <a href="http://developer.apple.com/techpubs/macosx/DeveloperTools/Compiler/Compiler.27.html" target="_blank">Double-Word Integers</a>
Chuck
___
"Instead of either 'multi-talented' or 'multitalented' use 'bisexual'."
     
Professional Poster
Join Date: Jul 2001
Location: Dis
Status: Offline
Reply With Quote
Jul 22, 2002, 08:33 PM
 
</font><blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">quote:</font><hr /><font size="1" face="Geneva, Verdana, Arial, sans-serif">Originally posted by Chuckit:
<strong>This looks like what you're looking for: <a href="http://developer.apple.com/techpubs/macosx/DeveloperTools/Compiler/Compiler.27.html" target="_blank">Double-Word Integers</a></strong></font><hr /></blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">Yes, thank you! I guess I should check Apple's documentation from time to time <img border="0" title="" alt="[Wink]" src="wink.gif" /> . Thank you very much, you've saved me a ton of work.

Thanx
BlackGriffen
I do not feel obliged to believe that the same God who has endowed us with sense, reason, and intellect has intended us to forgo their use. -Galileo Galilei, physicist and astronomer (1564-1642)
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 12:34 PM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2