Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Best way to check for 64-bit support

by jo37 (Deacon)
on Sep 07, 2021 at 18:24 UTC ( [id://11136535] : note . print w/replies, xml ) Need Help??


in reply to Best way to check for 64-bit support

With Config.pm you could check for d_quad. Another funny way to find the internal integer size is

perl -E 'say unpack "%b*", pack "j", -1'

Greetings,
-jo

$gryYup$d0ylprbpriprrYpkJl2xyl~rzg??P~5lp2hyl0p$

Replies are listed 'Best First'.
Re^2: Best way to check for 64-bit support
by LanX (Saint) on Sep 07, 2021 at 21:08 UTC
    similar idea, slightly shorter :)
    DB<10> p length sprintf '%b',-1 64

    but reliability may be effected by various math pragmas ...

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    Wikisyntax for the Monastery