On Wed, Apr 16, 2008 at 12:09 PM, Hans Bulfone <[EMAIL PROTECTED]> wrote: > On Wed, Apr 16, 2008 at 11:38:44AM -0700, Martin DeMello wrote: > > Ah - okay, if it's serialisation-specific, it's not what I'm looking > > for. I was looking for an analogue to the C trick of interpreting a > > block of bits as a struct quickly and efficiently. > > maybe you can use define-foreign-record to define the struct. > but this doesn't work at the bit level, afaik there is no way to say > e.g. unsigned int flag : 1; > > see http://chicken.wiki.br/Accessing%20external%20objects > and http://chicken.wiki.br/Foreign%20type%20specifiers
Thanks, define-foreign-record looks like what I wanted. The bit-accessors were just a hope - C doesn't really have much support for them either. martin _______________________________________________ Chicken-users mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/chicken-users
