Re: Tcl vs. Lua



Cameron Laird wrote:
>Tcl supports Unicode and regular expressions more fully
>than Lua.

Indeed, strictly speaking Lua doesn't have regular expressions at all.
It has pattern matching with some wildcards and character classes but
it lacks both alternation (e.g. cat|dog) and closure of subexpressions
(e.g. (ab)*).

Some things can be made to work in UTF-8 since Lua is 8-bit clean but
the short answer regarding Unicode support is that it doesn't. There is
a library that provides alternative string functions that work with
UTF-8. If you need to do a wee bit of Unicode you can probably make it
work but Lua is not designed to make Unicode easy. For details see:
http://lua-users.org/wiki/LuaUnicode.

.



Relevant Pages

  • Using Regular Expressions to process strings with unicode
    ... regular expressions), but I just can't seem to figure it out. ... contains unicode in it. ... string I am trying match is: ... or complains about an Unclosed Character ...
    (comp.lang.java.help)
  • Reding unicode characters?
    ... Could any one help me in writing a method which reads all Unicode ... characters supported in ruby or else using regular expressions. ... Jose Martin ...
    (comp.lang.ruby)
  • Re: Reding unicode characters?
    ... Could any one help me in writing a method which reads all Unicode ... characters supported in ruby or else using regular expressions. ... Jose Martin ... Ruby does not support unicode. ...
    (comp.lang.ruby)
  • Re: Support for Unicode strings
    ... support for Unicode strings would be essential. ... > includes the correct handling of unicode strings in regular expressions, ... Ruby does just fine with most applications of Unicode. ...
    (comp.lang.ruby)