Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

Re^2: Is there a 64-bit hex()?

by Minok (Novice)
on Feb 10, 2009 at 19:52 UTC ( #742864=note: print w/replies, xml ) Need Help??

in reply to Re: Is there a 64-bit hex()?
in thread Is there a 64-bit hex()?

I just want to clarify my understanding here.

So perl is providing the decimal equivalent of the 64 bit hex string given to it by saying that this hex string is equivalent to the following decimal number: 4,503,597,463,175,164.

The remaining question is about portability, or more specifically, will you get the same value regardless on which machine you run this perl code (ie would some other run produce a different decimal representation (assuming all would agree to interpret a 64 bit hex number as a 64-bit unsigned integer representation without any Endian manipulation needed, that is just straight binary from MSbit to LSbit from left to right) )?

And/Or would one even get an answer on some other machine (would some Perl interpreter, running on some hardware, not provide any result) ?

Replies are listed 'Best First'.
Re^3: Is there a 64-bit hex()?
by JavaFan (Canon) on Feb 10, 2009 at 21:29 UTC
    If you get a different result on a different platform, assuming both perls are compiled with 64-bit integers you have discovered a currently unknown bug.

    But you are likely to get a different result if you do the same with 32-bit integer perl.

    The portability issue the warning warns about is the portability between 32-bit and 64-bit perls. (perls, not hardware).

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://742864]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (7)
As of 2020-07-13 11:29 GMT
Find Nodes?
    Voting Booth?

    No recent polls found