Skip to content

Commit 6a9ebea

Browse files
committed
Fix type instability
1 parent a752fa3 commit 6a9ebea

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/basekernels/matern.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ struct MaternKernel{Tν<:Real} <: SimpleKernel
1616
end
1717

1818
@inline function kappa::MaternKernel, d::Real)
19-
ν = first.ν)
20-
return ifelse(iszero(d), one(d), _matern(ν, d))
19+
result = _matern(first.ν), d)
20+
return ifelse(iszero(d), one(result), result)
2121
end
2222

2323
function _matern::Real, d::Real)

0 commit comments

Comments
 (0)