lua-users home
lua-l archive

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

On Thu, Feb 9, 2012 at 6:29 AM, Jay Carlson <> wrote:
> On Wed, Feb 8, 2012 at 7:10 PM, Sam Roberts <> wrote:
>> I'm slightly baffled as to why this long conversation about unicode
>> support in lua doesn't seem to acknowledge that the features requested
>> already exist, AFAICT, see
>> icu4lua and slnunicode at end of
> No, the features I'm talking about don't exist for several reasons,
> starting from first not wanting a feature but a metamechanism where
> features could go.

I thought one thing folks might have wanted a utf-8/text aware version
of string, and slnunicode appears to be that.

> It doesn't help you in the task of producing valid text or debugging
> said failure, especially when spanning module/author boundaries.

Not sure what that means. Valid multilingual text can be typed into
lua code now, there was a chinese example in this thread.

> I disagree with your "assessment", but thanks for the dismissive drive-by.

I though my comments were constructive, actual code or API proposals
are easier to comment on than abstractions.

With Roberto's suggested API, there appear to be 3 APIs ranging from
his tiny one, to slnunicode, icu4lua.

> Lua's current approach strongly implies that the only relevant
> operations on text are single-byte ones. Had the language been

I'd say that it implies that single-byte operations can be used as a
building block for more complex ones.

> [1]: Actually, I've proposed pointing _G.string at text-centric
> functions in a UTF-8 mode as a "what-if", but I don't think you're
> paying attention enough to argue with this statement.

Argue with what statement? Why would I want to argue with anybody, anyhow?

_G.string = slnunicode would work great for some apps.