[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Feature proposal: \x## notation in strings
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Wed, 11 Mar 2009 23:20:12 -0300
> Is this defined or undefined behavior in Lua 5.1?
> assert( "\x10" == "x10" ) -- not [[\x10]]
> assert( "\;" == ";") -- not [[\;]]
Undefined because the manual does not list \x as an escape sequence.
The current implementation does ignore the \ in this case, but that
should not be relied upon.
Anyway, the manual seems pretty clear to me:
Literal strings [...] can contain the following C-like escape sequences:
The key word here is "the".