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

Fix NaN for non-number types #3193

Merged
merged 4 commits into from Apr 24, 2024
Merged

Conversation

lgerin
Copy link
Contributor

@lgerin lgerin commented Apr 19, 2024

Fixes #3192

This is my first PR on an open project, give as much feedback as you like.

While doing this I realized that this didn't only affect units, but also Complex, BigNumber, etc -> anything that wasn't a straight up number was getting sent directly to the Number.isNaN function, which automatically sets false for non-number types.

Also added a test case for this.

@josdejong
Copy link
Owner

Thanks Laurent, this looks good 👌

@josdejong josdejong merged commit 81d2e71 into josdejong:develop Apr 24, 2024
7 checks passed
@josdejong
Copy link
Owner

Published in v12.4.2, thanks again!

@lgerin lgerin deleted the fixIsNaNArrays branch April 24, 2024 17:19
@lgerin
Copy link
Contributor Author

lgerin commented Apr 24, 2024

Thanks @josdejong ! :-)

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.

isNaN() returns false for a NaN unit in a matrix or array
2 participants