On Feb 8, 2008 9:13 AM, Galchin Vasili [EMAIL PROTECTED] wrote:
Let's take a concrete but made up case .. suppose we want to call through
to pthread_create and pass the (void *) argument to pthread_create which in
turn gets interpreted by the pthread that is launched. How would one
populate
Let's take a concrete but made up case .. suppose we want to call through
to pthread_create and pass the (void *) argument to pthread_create which in
turn gets interpreted by the pthread that is launched. How would one
populate the C struct that is passed to the launched pthread keeping in mind
a couple of concrete examples:
typedef struct {char a; int b; char str[8]} type1;
typedef struct {long c; char d} type2;
So to pthread_create (just an example function) we could be passing a struct
of type1 or a struct of type2 .. i.e. arbitrary length and content ... I am
trying to better
basically I am trying to implement ioctl for the Posix library .. so a
possible signtaure would be:
fdIoctl :: Fd - Int - Ptr Word 8 - IO( Ptr Word8)
Vasili
On 2/8/08, Galchin Vasili [EMAIL PROTECTED] wrote:
a couple of concrete examples:
typedef struct {char a; int b; char str[8]}
On Feb 8, 2008 10:57 AM, Galchin Vasili [EMAIL PROTECTED] wrote:
basically I am trying to implement ioctl for the Posix library .. so a
possible signtaure would be:
fdIoctl :: Fd - Int - Ptr Word 8 - IO( Ptr Word8)
Ah, ok. You could cover many of the ioctls (the ones which only take a
Hello,
Ok .. I am writing a Haskell function that will call down into the ANSI
C library .. blah :: - Ptr Word8 - The underlying C function
that blah is calling has a void * so I am using Ptr Word 8 to model
the void *. I propose to have the callers of function blah to