Skip to content

Commit 13a6637

Browse files
authored
handle literal_pow (#143)
* src/methods.jl: C
1 parent 10edc17 commit 13a6637

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/methods.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,5 +135,6 @@ function cond(_if::Symbolic{Bool}, _then, _else)
135135
Term{Union{symtype(_then), symtype(_else)}}(cond, Any[_if, _then, _else])
136136
end
137137

138-
# Specially handle inv
138+
# Specially handle inv and literal pow
139139
Base.inv(x::Symbolic) = Base.:^(x, -1)
140+
Base.literal_pow(::typeof(^), x::Symbolic, ::Val{p}) where {p} = Base.:^(x, p)

0 commit comments

Comments
 (0)