[M3devel] Referencing opaque C structs in M3 code?

Mika Nystrom mika at async.async.caltech.edu
Thu Mar 4 22:49:17 CET 2010


Ctypes.void_star is already what you want.  It's supposed to behave
like a (void *), which I think is what you want?

You can also use ADDRESS but it's a bit less clear, I think.

     Mika

Chris writes:
>Alright, this has thrown me for a bit of a loop...no pun intended...
>
>Suppose I'm linking my Modula 3 code with a C library where the public API has
> a declaration like this...
>
>typedef struct opaque_foo_t opaque_foo_t;
>
>And the type opaque_foo_t is defined in the private part of the library.
>
>Do I need to create a seperate representation of the structure for my Modula3 
>program or can I just create a pointer for it and pass the pointer around? Ass
>uming of course I dont have to actually reference anything inside opaque_foo_t
>.  Would I just create an UNTRACED REF Ctypes.void_star or something similiar?
>
>I'm a little puzzled. Any help would be appreciated.
>
>
>
>-- 
>Chris <Highjinks at gmx.com>



More information about the M3devel mailing list