Skip to content

Preserve negative zero during boxing - #1476

Open
tobil4sk wants to merge 2 commits into
HaxeFoundation:masterfrom
tobil4sk:fix/box-negative-zero
Open

tobil4sk wants to merge 2 commits into
HaxeFoundation:masterfrom
tobil4sk:fix/box-negative-zero

Conversation

@tobil4sk

Copy link
Copy Markdown
Member

Negative zero turns into positive zero during boxing, discovered in: HaxeFoundation/haxe#13249

Somewhat related to #1278

-0.0 is equal to 0 under ==, so the boxing optimisation replaced it with
0.
This optimisation is not valid, because -0.0 has different behaviour
when used as a divisor compared with 0.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant