lua-users home
lua-l archive

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

David Jones <> writes:

> string.byte should probably be named string.code to avoid any
> emotional attachment to byte.

Possibly.  At least it would be sensible to provide those aliases in
the unicode class and pronounce them preferable.

> Whilst almost all bytes are 8-bit (octets), byte does have other
> meanings apart from 8-bit number.  Google for "14-bit byte", etc.

Uh, no.  The "14-bit byte" is a misnomer for 14-bit patterns
representing 8-bit bytes.  I could equally well talk of "three-digit
bytes" for the "\045" string representations, and it would not make a
byte mean 3 digits.  There are no more than 2^8 valid "three-digit
bytes", and there are no more than 2^8 "14-bit bytes".

David Kastrup