Skip to content

Commit 29d8280

Browse files
committed
Eliminate redundant call to norm
1 parent 3b3791f commit 29d8280

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/rulesets/LinearAlgebra/norm.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
function frule((_, Δx), ::typeof(norm), x)
66
y = norm(x)
7-
return y, _norm2_forward(x, Δx, norm(x))
7+
return y, _norm2_forward(x, Δx, y)
88
end
99

1010
function frule((_, ẋ), ::typeof(norm), x::Number, p::Real)

0 commit comments

Comments
 (0)