PATCH: Support for Pascal strings

Stan Shebs shebs@apple.com
Thu Jun 21 17:44:00 GMT 2001


Mark Mitchell wrote:
> 
> Good.  Can we negotiate the unsignedness?
> 
> I cannot imagine very many people rely on this particular aspect of the
> extension.  In we can make "\p..." be a plan `char' --- signed or unsigned
> in the same way that "..." would be -- then we are in business.  In that
> case, we just have the preprocessor replace \p with the length byte, and
> that is it.  The change then becomes extremely minimal, both in terms of
> semantics and in terms of code.

That was my instant reaction to that aspect of the patch too, so I
had Zem be the sacrificial victim (can you see a pattern here :-) )
and ask on one of Apple's internal lists, the one where all the old
Mac programmers hang out.  The response was swift and negative, and
they also pointed out what I should have remembered, because I've
used it myself - the Mac headers have a Str255 typedef that is
unsigned char.  Also, bad things could happen if you tried to dig
out the length byte of a 128 - 255-byte-long string and use it.

(Zem is on a trip until the middle of next week BTW.)

Stan



More information about the Gcc-patches mailing list