davidgiven / wordgrinder

A word processor which gets the hell out of your way and lets you get some work done.
http://cowlark.com/wordgrinder
978 stars 61 forks source link

build error: malformed number #239

Closed kbarni closed 1 year ago

kbarni commented 1 year ago

I get a "Malformed number" error while building the LUA files:

Lua error: [string "src/lua/_prologue.lua"]:67: Malformed number

This happens for every floating point number declaration.

It seems that it expects comma as decimal separator (as I can solve it by replacing 0.8 by 0,8).

As a workaround, I set LC_NUMERIC to en_US from fr_FR

I wonder if it's possible to set it by default ? Probably put a os.setlocale("C") somewhere?

davidgiven commented 1 year ago

Changing LC_NUMERIC to fr_FR doesn't duplicate that for me, but I believe you... that sounds like a Luau bug.

Could you do an update (I've just make a change), then do:

make clean; make NINJAFLAGS="-j1 -v"

...and attach the build log, please?

kbarni commented 1 year ago

Here's the build log

BTW, my current locale settings:

LANG=en_US.UTF-8
LANGUAGE=en_U

LC_CTYPE=C
LC_NUMERIC=fr_FR.UTF-8
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY=fr_FR.UTF-8
LC_MESSAGES="en_US.UTF-8"
LC_PAPER=fr_FR.UTF-8
LC_NAME=fr_FR.UTF-8
LC_ADDRESS=fr_FR.UTF-8
LC_TELEPHONE=fr_FR.UTF-8
LC_MEASUREMENT=fr_FR.UTF-8
LC_IDENTIFICATION=fr_FR.UTF-8
LC_ALL=
davidgiven commented 1 year ago

I can duplicate it --- thanks!