chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] working with bit- and byte-level structures


From: Hans Bulfone
Subject: Re: [Chicken-users] working with bit- and byte-level structures
Date: Wed, 16 Apr 2008 21:09:55 +0200
User-agent: Mutt/1.5.16 (2007-06-09)

hi,

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

hth&bye,
hans.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]