lua-users home
lua-l archive

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


On Mon, Sep 27, 2010 at 2:54 AM, Xpol Wan <xpolife@gmail.com> wrote:
> Hi guys,
>
>     Is it possible to add utf-8 lua source support in lua 5.2?
> Just remove the BOM of the utf-8 lua source file when loading a lua file of
> string.
>
> I know it is just a little patch, but it would be nice to include this
> feature in the official lua.
>
>
> Best Regards!
>
> Xpol Wan
>

To be honest, it seems only fair to me, since Lua's standard script
file loader already supports ignoring the first line if it begins with
a shebang. This sets a precedent that it is appropriate for the loader
to ignore common, OS-specific pecularities at the beginning of a
script file.

-Duncan