Re: binary scan and signed characters
- From: Arjen Markus <arjen.markus@xxxxxxxxxx>
- Date: Sat, 30 Aug 2008 03:26:42 -0700 (PDT)
On 30 aug, 10:20, "Donal K. Fellows" <donal.k.fell...@xxxxxxxxx>
wrote:
Arjen Markus wrote:
My question: is this platform-dependent behaviour? Is it because the
underlying C run-time library regards characters as signed? Or is Tcl
using signed characters and this behaviour is by design?
It's consistently that way, and I think it's because 'i'nts are also
signed, and that was how they had to be back when [binary] was
introduced on 32-bit platforms. 8.5 lets force an unsigned
interpretation with the 'u' flag, documented in TIP #275.
Donal.
Ah, right, I looked for something like that, but missed it (I looked
in
the list of format codes, but it is described in the introduction to
[binary scan]).
Thanks,
Arjen
.
- References:
- binary scan and signed characters
- From: Arjen Markus
- Re: binary scan and signed characters
- From: Donal K. Fellows
- binary scan and signed characters
- Prev by Date: Re: Idea for new ttk Notebook virtual event
- Next by Date: Converting a (big) canvas to an image
- Previous by thread: Re: binary scan and signed characters
- Next by thread: Tcl 8.5 and special numbers
- Index(es):