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

Re^4: XS: returning a 64-bit unsigned int?

by ikegami (Pope)
on Sep 27, 2011 at 07:21 UTC ( #928031=note: print w/ replies, xml ) Need Help??


in reply to Re^3: XS: returning a 64-bit unsigned int?
in thread XS: returning a 64-bit unsigned int?

Perl claims the right to convert among equivalent representations. It's an optimisation that an UV isn't used unless needed since UVs require extra handling.

>perl -MDevel::Peek -e"Dump(0x7FFFFFFF)" SV = IV(0x1de9d00) at 0x1de9d04 REFCNT = 1 FLAGS = (PADTMP,IOK,READONLY,pIOK) IV = 2147483647 >perl -MDevel::Peek -e"Dump(0x80000000)" SV = IV(0x4a9d00) at 0x4a9d04 REFCNT = 1 FLAGS = (PADTMP,IOK,READONLY,pIOK,IsUV) UV = 2147483648


Comment on Re^4: XS: returning a 64-bit unsigned int?
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (8)
As of 2015-07-08 03:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (94 votes), past polls