lua-users home
lua-l archive

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


This part of the bytecode corresponds to the source file name.

0x40 is @, the first character of "source" string. 0x2e5c is ".\" which only occurs on Windows.

0x8a and 0x8c are encodings of the string length. The difference of 2 is explained by the added ".\" on Windows as well.

-- 
Pierre Chapuis


On Wed, May 6, 2020, at 00:29, Vinicius Jarina wrote:
Hello

(sending again without the image)

Running a couple of tests of NLua with Lua 5.4.0 rc2 I noticed the binary created using luac on linux/mac is slight different from luac on Windows. (Both on x64)

I have this small test.lua https://gist.github.com/viniciusjarina/084ec517d9b20756043e0296748f728d

The result compiling with luac on windows is this one: https://gist.github.com/viniciusjarina/303a9183f1170e2fdb6031f49f7e71ba
and on Linux/Mac: https://gist.github.com/viniciusjarina/b936342b748be339022f542a47ef6e63

The two outputs are almost identical, but around byte 34 instead of 8C 40 2E 5C on windows is 8A 40,

I know in theory the compiled bytecode shouldn't be "portable" but this wasn't happening in previous versions of Lua, so I guess worth report in case could be a regression on 5.4.0

Thank you.

On Tue, May 5, 2020 at 5:12 AM Luiz Henrique de Figueiredo <lhf@tecgraf.puc-rio.br> wrote:
Lua 5.4.0 (rc2) is available for testing at
        http://www.lua.org/work/
Download it and give it a try.

We thank everyone for their feedback on Lua 5.4.0 till now.

If there is no further feedback on Lua 5.4.0, we'll freeze it next week,
and it will become the current release of Lua.

All feedback welcome. Thanks.
--lhf
_______________________________________________
lua-l mailing list -- lua-l@lists.lua.org
To unsubscribe send an email to lua-l-leave@lists.lua.org
_______________________________________________
lua-l mailing list -- lua-l@lists.lua.org
To unsubscribe send an email to lua-l-leave@lists.lua.org


_______________________________________________
lua-l mailing list -- lua-l@lists.lua.org
To unsubscribe send an email to lua-l-leave@lists.lua.org