Long integer problem
BlitzMax Forums/BlitzMax Programming/Long integer problem
| ||
I just cant believe this is happening. Global uid:Long = $bbbbbbbbb 'that is 8*b Print LongHex(longl) displays FFFFFFFFBBBBBBBB Global uid:Long = $bbbbbbbbbb 'that is 7*b Print LongHex(longl) displays 00000000BBBBBBB This is scary - I have tried all kinds of stuff with LONG - something up ? I'm sure someone else would have noticed this. I'm using version 1.4 and 1.42 Linux and win same problem. Any ideas? |
| ||
Try appending ":Long" to your numeric literals if you want them to come out properly as 64-bit instead of being converted via 32-bit:Global uid:Long = $bbbbbbbbb:Long |
| ||
Well thankyou kindly - I have been pulling my hair out - wish I had asked earlier. |
| ||
I still occasionally forget that floating point numeric literals default to single precision. |