>
> B)  When passing char *string on C, should I use
> the CString or the Ptr CChar marhalling type from FFI ?
>

Ok. I see. Definition for CSTring is

type CString = Ptr CChar


C) CInt, CDouble are available...but, concerning Storable class.

Given:
typedef struct _foostruct {
    int a;
    double b;
} fooStruct, *fooStructPtr;

How to do to marshall  it to Haskell ?

type CFooStruct = ???

instance Storable CFooStruct where
   sizeOf _ = ???
   peekElement _ = ????

-- Next is certainly OK, provided well defined CFooStruct
type CFoosStructPtr = Ptr CFooStruct


I need it to marshall the Maple kernel handle into Haskell...



> _______________________________________________
> FFI mailing list
> [EMAIL PROTECTED]
> http://www.haskell.org/mailman/listinfo/ffi
>
_______________________________________________
FFI mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/ffi

Reply via email to