[BUG][FIX] FFI ExternalType>>isIntegerType

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[BUG][FIX] FFI ExternalType>>isIntegerType

Igor Stasenko
ExternalType signedLongLong isIntegerType
answers false

but:

ExternalType unsignedLongLong isIntegerType
answers true

Here's a fix:

isIntegerType
        "Return true if the receiver is a built-in integer type"
        | type |
        type := self atomicType.
- ^type > FFITypeBool and:[type <= FFITypeUnsignedLongLong]
+ ^type > FFITypeBool and:[type <= FFITypeSignedLongLong]

--
Best regards,
Igor Stasenko AKA sig.