Closed Kodiologist closed 10 years ago
Hi,
\t, \n etc are escaped on purpose. The rationale is that I want to be able to distinguish between " "
(a bunch of spaces) and the \t
character.
I can't escape all non-printing characters, since they could be part of a more complex unicode string. Handling unicode goes beyond the scope of the lib though. So I am closing this.
I see your point with respect to Unicode.
The rationale is that I want to be able to distinguish between
" "
(a bunch of spaces) and the\t
character.
I agree, but shouldn't the result of inspect("\n")
display as "\n"
rather than "\\n"
? In other words, shouldn't inspect("\n")
return the Lua value "\\n"
rather than the Lua value "\\\\n"
? One is the correct escape sequence and the other isn't.
Hey, you are right about that. Reopening this, will investigate. Thanks!
I'd be happy to take a shot at writing a patch if you'd like.
It would help a lot if you could do that. I have spent Christmas with my family and was mostly offline. I am a bit swamped right now :)
Closed by b718a2e55c7dd4b8e8e80718041c49a768c8271d