Skip to content

Conversation

@detaoin
Copy link

@detaoin detaoin commented Dec 16, 2024

When testing the C lua compiler (binary dump) differences, the test failed TestParserExhaustively in lua-tests/attrib.lua with parser_test.go:134: 153: 1.0000000000000001e+33 != 1e+33.
This is caused by different implementations of math.Pow in Go, and C pow functions.

I also replaced calls to executable luac with luac5.2; at least on recent Debian and Ubuntu versions, lua version 5.2 compiler is named so. (otherwise lua 5.4 would be used today)

Diego Joss added 3 commits December 16, 2024 22:17
At least on Debian (and derived distributions), the luac compiler for
version 5.2 is explicitly named luac5.2. Otherwise, today, version 5.4
is used instead.
It is known that the Go stdlib math functions may give different results
than the C equivalents. See golang/go#25270
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant