Open ennorehling opened 2 years ago
Yes, unfortunately TinyJS isn't very spec compliant. It hasn't been maintained in ages - you may find that other engines like mjs
do a better job for you?
Honestly the best bet would probably be to rip out all the integer maths stuff - it'd simplify the code quite a bit and would then be spec compliant.
I didn't know about mjs
, but that looks like it will work. Thanks!
TinyJS seems to treat integers differently from other numbers?
This doesn't match the behavior of other Javascript implementations, or indeed the wording at https://www.w3schools.com/js/js_numbers.asp:
And the standard explicitly says:
Is this intentional? Is there a way to make TinyJS behave like the standard? Perhaps a compile-time option could be added?