[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: utf-8 support (was: [ANN] Lua 5.1.2-rc3 now available)
- From: "Inmate 2993" <inmatarian@...>
- Date: Thu, 29 Mar 2007 20:50:47 -0400
David Kastrup wrote:
>> Apropos: could someone clue me in what the proposed way of operation
>> is for dealing with utf-8 strings? When one is using lua as an
>> embedded interpreter, having efficient strings with a natural Unicode
>> character type (internally represented with utf-8) would save a lot of
>>headaches.
Lua is already 8-bit clean when it comes to strings, so they can store UTF-8 with no problem. The issue at hand is input and output, and when you embed Lua into program, you would have to provide your own output method which took into account UTF-8 encoding. I've recently done this myself, and it's not too hard. The Wiki and RFCs associated with UTF-8 provide a lot of information. These links should help.
http://en.wikipedia.org/wiki/UTF-8
http://tools.ietf.org/html/rfc3629
--
William C. Bubel