-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Fixed norm #30481
Fixed norm #30481
Changes from 1 commit
68ff2bc
8829626
d63a87d
c6caf3b
d3e3235
445a52c
81ce237
eb23b9c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -225,6 +225,12 @@ end | |
end | ||
end | ||
|
||
@testset "Issue #30466" begin | ||
@test norm([typemin(Int), typemin(Int)], Inf) == 9.223372036854776e18 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You mean |
||
@test norm([typemin(Int), typemin(Int)], -Inf) == 9.223372036854776e18 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Did we discuss this anywhere? I'm not sure we should allow negative |
||
@test norm([typemin(Int), typemin(Int)], 1) == 1.8446744073709552e19 | ||
end | ||
|
||
@testset "potential overflow in normalize!" begin | ||
δ = inv(prevfloat(typemax(Float64))) | ||
v = [δ, -δ] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this isn't right either, since
v
might not be a scalar.