Skip to content

Commit 3b264aa

Browse files
committed
feat: Add support for extra keyword arguments to Div and Pow
1 parent 710f871 commit 3b264aa

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/types.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -469,7 +469,7 @@ function maybe_intcoeff(x)
469469
end
470470
end
471471

472-
function Div{T}(n, d, simplified=false; metadata=nothing) where {T}
472+
function Div{T}(n, d, simplified=false; metadata=nothing, kwargs...) where {T}
473473
if T<:Number && !(T<:SafeReal)
474474
n, d = quick_cancel(n, d)
475475
end
@@ -518,15 +518,15 @@ end
518518

519519
@inline denominators(x) = isdiv(x) ? numerators(x.den) : Any[1]
520520

521-
function Pow{T}(a, b; metadata=NO_METADATA) where {T}
521+
function Pow{T}(a, b; metadata=NO_METADATA, kwargs...) where {T}
522522
_iszero(b) && return 1
523523
_isone(b) && return a
524524
s = Pow{T}(; base=a, exp=b, arguments=[], metadata)
525525
BasicSymbolic(s)
526526
end
527527

528-
function Pow(a, b; metadata=NO_METADATA)
529-
Pow{promote_symtype(^, symtype(a), symtype(b))}(makepow(a, b)..., metadata=metadata)
528+
function Pow(a, b; metadata = NO_METADATA, kwargs...)
529+
Pow{promote_symtype(^, symtype(a), symtype(b))}(makepow(a, b)...; metadata, kwargs...)
530530
end
531531

532532
function toterm(t::BasicSymbolic{T}) where T

0 commit comments

Comments
 (0)