Long int data type?

Monkey Forums/Monkey Programming/Long int data type?

richo(Posted 2012) [#1]
Hi,

How are you all?

I'm writing a module for iOS & some of the return typesakin API functions are long integers. Would someone be kind enough to explain the best way to get long's (64 bit) back to Monkey code?

Thanks in advance :)


Beaker(Posted 2012) [#2]
Might be tricky. You could always convert them to strings or split them over 2 Ints or 4 bytes. What would you do with them once monkey has them?


invaderJim(Posted 2012) [#3]
If you don't need values that large, you could just cast your long int values as ints before you send them back to Monkey, which would require you to wrap those API functions.

Alternatively, you could modify the trans code to include a Long Int type :P


marksibly(Posted 2012) [#4]
Hi,

In some situations, you may be able to get away with something like:

Extern

Function blah()="(int)blah"