lua-users home
lua-l archive

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

On Thu, Jan 6, 2011 at 5:10 AM, David Manura <> wrote:
> BTW, [3] had an interesting related request about whether its possible
> to force memory alignment of string literals (and the answer is no).
> [3]

That may have been the case for Lua 4, but I was under the impression
that string literals were fully aligned since Lua 5, as the 5.0 / 5.1
reference manuals state that lua_to[l]string "returns a fully aligned
pointer to a string inside the Lua state", and TString is a union
against luaU_maxalign.