Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hashlink floating point exception with remainder operator #730

Open
PXshadow opened this issue Dec 7, 2024 · 1 comment
Open

Hashlink floating point exception with remainder operator #730

PXshadow opened this issue Dec 7, 2024 · 1 comment

Comments

@PXshadow
Copy link

PXshadow commented Dec 7, 2024

function main() {
	var x = (-1 << 31);
	var y = -1;
	trace(x % y);
}

Haxe nightly: c4868e5
Hashlink: 1.14.0

@Apprentice-Alchemist
Copy link
Contributor

In this case floating point exception actually means integer overflow.
This is an edge case that needs to be worked around either in genhl or in the JIT.

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

No branches or pull requests

2 participants