Skip to content

Commit

Permalink
Merge pull request #557 from contradict/nanmath-pow
Browse files Browse the repository at this point in the history
NaNMath.pow fix
  • Loading branch information
shashi authored Nov 9, 2023
2 parents 52b62f1 + fac570d commit 9ba270b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/methods.jl
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const monadic = [deg2rad, rad2deg, transpose, asind, log1p, acsch,

const diadic = [max, min, hypot, atan, NaNMath.atanh, mod, rem, copysign,
besselj, bessely, besseli, besselk, hankelh1, hankelh2,
polygamma, beta, logbeta]
polygamma, beta, logbeta, NaNMath.pow]
const previously_declared_for = Set([])

const basic_monadic = [-, +]
Expand Down
3 changes: 3 additions & 0 deletions test/code.jl
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,9 @@ nanmath_st.rewrites[:nanmath] = true
end)
@test toexpr(SetArray(true, a, [x(t), AtIndex(9, b), c])).head == :macrocall


@test toexpr(NaNMath.pow(a, b)) == :($(NaNMath.pow)(a, b))

f = GlobalRef(NaNMath, :sin)
test_repr(toexpr(LiteralExpr(:(let x=1, y=2
$(sin(a+b))
Expand Down

0 comments on commit 9ba270b

Please sign in to comment.