struct module...

Franck Bui-Huu Franck.BUI-HUU at gemplus.com
Fri Mar 21 13:00:18 EST 2003


yes but the counted length string must be just before the string

with ?X syntax you can use a length which can be stored wherever
you want (before the string yet)

Richard Brodie a écrit:

>"Tim Peters" <tim.one at comcast.net> wrote in message
>news:mailman.1048262974.10758.python-list at python.org...
>
>  
>
>>>did someone extend struct module to manage not fixed lengh of
>>>array.
>>>      
>>>
>>Doesn't seem worth the confusion or bother to me.
>>    
>>
>
>The p format does seem to have rather curious semantics; I would
>have thought the 'least surprising' thing would be for it to take a string
>and store it as a counted length string.
>
>'B?(1)c' looks like ugly syntax though. What about *p for an implied
>length byte-counted string?
>
>
>  
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20030321/06455c0b/attachment.html>


More information about the Python-list mailing list