language: Perl
licence: Other
64-bit Number from a String
Useful for int64_t input parameters, like what CGEventSourceSetUserData needs
The string in the foreach() loop needs to have a length of 8
Probably doesn't work if your string contains wide characters
perl -MMath::BigInt -e '$x=Math::BigInt->bzero(); foreach(split(//,"Hi_There")){printf("$_\t%d\n",ord($_)); $x <<= 8;$x+=ord($_);} print "$x\n";'



library
objective-c (22)