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 norm of StaticArrays with non-finite elements #1161

Merged
merged 3 commits into from
May 14, 2023

Conversation

gerlero
Copy link
Contributor

@gerlero gerlero commented May 12, 2023

Fixes #1135 by making the functionality introduced in #975 play nicer with arrays that contain NaN or (±)Inf elements. This removes an unexpected dependence of the return of norm() on the ordering of the elements in these cases, and also makes the results consistent with regular Julia arrays.

(Thanks to @rmkn85 for the help in tracing the cause of this one)

EDIT: fix typos

@gerlero
Copy link
Contributor Author

gerlero commented May 13, 2023

CI failures with Julia nightly are because of #1162

@gerlero
Copy link
Contributor Author

gerlero commented May 13, 2023

Re the Nightly CI fails, #1162 is now fixed (I can update the PR branch if desired) but #1155 still remains.

Both appear unrelated, so I'd like to see this reviewed anyway if at all possible.

Copy link
Collaborator

@mateuszbaran mateuszbaran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Could you just bump patch version? I will wait a couple of days before merging in case someone has some remarks.

@gerlero
Copy link
Contributor Author

gerlero commented May 13, 2023

LGTM. Could you just bump patch version? I will wait a couple of days before merging in case someone has some remarks.

Thanks! Sure; done.

Copy link
Collaborator

@hyrodium hyrodium left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@hyrodium hyrodium merged commit d9d54bd into JuliaArrays:master May 14, 2023
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.

isapprox returns wrong results with nans=true
3 participants