lua-users home
lua-l archive

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

It was thus said that the Great Tom N Harris once stated:
> On 06/28/2011 04:24 PM, Lorenzo Donati wrote:
> >Unicode escape sequences are platform independent. They are useful for
> >the same reasons why ASCII codes are useful, at least for people working
> >with Unicode.
> >
> Technically, Lua doesn't even require ASCII, as the recent adventures 
> with lctype.c have shown. Unicode is platform specific because not all 
> platforms use the same encoding (UTF-8 vs UTF-16). And when Unicode 
> isn't being used at all this will just be dead-weight in the parser.
> How about supporting escape sequences greater than 255 when sizeof(char)>1 ?

  The C standard dictates that sizeof(char) == 1.  You instead want to check
CHAR_BIT from limits.h.

  -spc (Or CHAR_MAX/UCHAR_MAX ... )