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

Binary manipulation

What is the best way to do binary manipulation of data within MCL?
I need to do the equivalent of shifts, ands, nors, ors, etc., but the problem
I'm having is doing these with integers and fixnums  How would you convert the following
to mcl:

	short var1 47;
	unsigned long var2 0x322459;

	*((var1 & 0x7 << 3) + var2)

going back and forth between MCL fixnum and bit-arrays (without losing data)?


Jeffrey Kane, MD
Kane Biomedical Systems
Boston, MA

Internet    jbk@world.std.com
Compuserve  74206,640
AppleLink   D0738

[Don't take life too seriously... it's not like anyone gets out of it alive.]