Parsing Binary Structures; Is there a better way / What is your way?

Martin P. Hellwig martin.hellwig at dcuktec.org
Wed Aug 5 15:41:26 EDT 2009


Paul Rubin wrote:
> "Martin P. Hellwig" <martin.hellwig at dcuktec.org> writes:
>> Is there an advantage using shifts and masks over my kitchen type solution?
> 
> Weren't you complaining about the 8-to-1 expansion from turning each bit
> to an ascii char?

Yes you are (of course) right, my 'dream' solution would be something 
that accepts slice indeces on bit level. Your reasoning did reveal some 
flaws in my approach though ;-)

-- 
MPH
http://blog.dcuktec.com
'If consumed, best digested with added seasoning to own preference.'



More information about the Python-list mailing list