Abidi Nadji

Results 11 comments of Abidi Nadji

the weirdest thing is how its still working on linux with no error using the same bindings

For example: * This works: ``` nelua -i "local INT_FAST16_MAX: clong = 9223372036854775807; print(INT_FAST16_MAX)" ``` * This does not work: ``` nelua -i "local INT_FAST16_MAX: clong = 9223372036854775807; print(INT_FAST16_MAX)" --cc="zig...

the same error ``` λ ~ nelua -i "local INT_FAST16_MAX: clong = 9223372036854775807; print(INT_FAST16_MAX)" --cc="zig cc -target x86_64-windows" eval_HzkndbMsuES:1:1: from: AST node Block local INT_FAST16_MAX: clong = 9223372036854775807; print(INT_FAST16_MAX) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~...

using wine it return ``` 4294967295 ```

yeah, but still does not compile for windows 64-bit while working fine for 64-bit linux

so i'm confused about the default behavior of the compiler, does it allow overflow at compile time or not

> the same error > > ``` > λ ~ nelua -i "local INT_FAST16_MAX: clong = 9223372036854775807; print(INT_FAST16_MAX)" --cc="zig cc -target x86_64-windows" > eval_HzkndbMsuES:1:1: from: AST node Block > local...

the nelua compiler, C compilers allow that

Yes i understand the issue correctly. you can try to assign this big number to an integer in C and it would compile with some overflow warnings, even for 32-bit...