[plt-scheme] BitField
Paulo Jorge O. C. Matos wrote:
> Last week I was in need to control bits to implement RC4 private key
> algorithm in
> PLTScheme and I was not able to find something that would allow me to
> check
> bits and move them around, etc so I created a little module of
> bitfield operations.
> Unfortunately I think it could be better but had no better idea. The
> library is at:
> http://mega.ist.utl.pt/~pocm/bitfield.ss
I think you missed the bitwise operations. At first I overlooked them
too, when
I implemented the md5 algorithm:
http://www.scheme.dk/md5/md5.html
If you try it, then use time to see the difference between the builtin
operations
and the userdefined. There is a world of difference.
Take also a look at Olin Shivers proposal for an integer bitwise-operation
library:
http://srfi.schemers.org/srfi-33/srfi-33.txt
This looks very nice.
--
Jens Axel Søgaard