You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
julia> using Test, Polynomials
julia> p =ImmutablePolynomial((1,))
ImmutablePolynomial(1)
julia> q =Polynomial([10, 20])
Polynomial(10 + 20*x)
julia> @inferredq(p)
ERROR: return type Polynomials.ImmutableDensePolynomial{Polynomials.StandardBasis, Int64, :x, 1} does not match inferred return type Any
It doesn't make sense for this composition to return an ImmutableDensePolynomial, because that makes type stability impossible, because the degree of q is not available in the type domain.
The text was updated successfully, but these errors were encountered:
Hmm, not sure what is right here, as q(p) will return something with container type of p in other cases. The mixed case is tricky with immutable polynomials.
With v4.0.0:
It doesn't make sense for this composition to return an
ImmutableDensePolynomial
, because that makes type stability impossible, because the degree ofq
is not available in the type domain.The text was updated successfully, but these errors were encountered: