It should return long or int as nativeType, based on the value of
Native.LONG_SIZE. Returning a NativeMapped nativeType of NativeMapped
would be cursive again.
On Sep 22, 2008, at 5:16 PM, Duncan McGregor wrote:
Its late here, so I apologise for what may be a question with an
obvious answer.
Can I return NativeLong from the result of a Function invocation?
I have a TypeMapper that returns NativeLong.class from nativeType(),
but this just leads to
java.lang.IllegalArgumentException: Unsupported return type class
com.sun.jna.NativeLong in function objc_msgSend
at com.sun.jna.Function.invoke(Function.java:348)
at com.sun.jna.Function.invoke(Function.java:223)
at org.rococoa.MsgSendHandler.invoke(MsgSendHandler.java:90)
at com.sun.jna.Library$Handler.invoke(Library.java:202)
at org.rococoa.$Proxy0.syntheticSendMessage(Unknown Source)
at org.rococoa.Foundation.send(Foundation.java:183)
at org.rococoa.Foundation.send(Foundation.java:170)
as there is no Function.invokeNativeLong()
Am I missing something obvious, staring at the screen with bloodshot
eyes?