@@ -217,16 +217,17 @@ end
217
217
@inline - (a:: STaylor1 ) = STaylor1 (minus_tuple (a. coeffs))
218
218
219
219
function + (a:: STaylor1{N,T} , b:: T ) where {N, T<: Number }
220
- STaylor1 {N,T} (ntuple (i -> i == 1 ? a. coeffs[1 ] + b : a. coeffs[i], N ))
220
+ STaylor1 {N,T} (ntuple (i -> i == 1 ? a. coeffs[1 ] + b : a. coeffs[i], Val (N) ))
221
221
end
222
222
function + (b:: T , a:: STaylor1{N,T} ) where {N, T<: Number }
223
- STaylor1 {N,T} (ntuple (i -> i == 1 ? a. coeffs[1 ] + b : a. coeffs[i], N ))
223
+ STaylor1 {N,T} (ntuple (i -> i == 1 ? a. coeffs[1 ] + b : a. coeffs[i], Val (N) ))
224
224
end
225
225
function - (a:: STaylor1{N,T} , b:: T ) where {N, T<: Number }
226
- STaylor1 {N,T} (ntuple (i -> i == 1 ? a. coeffs[1 ] - b : a. coeffs[i], N ))
226
+ STaylor1 {N,T} (ntuple (i -> i == 1 ? a. coeffs[1 ] - b : a. coeffs[i], Val (N) ))
227
227
end
228
228
- (b:: T , a:: STaylor1{N,T} ) where {N, T<: Number } = b + (- a)
229
229
230
+ # +(a::STaylor1{N,T}, b::S) where {N, T<:NumberNotSeries, S<:NumberNotSeries} = +(promote(a,b)...)
230
231
# +(a::STaylor1{N,T}, b::STaylor1{N,S}) where {N, T<:NumberNotSeries, S<:NumberNotSeries} = +(promote(a,b)...)
231
232
# +(a::STaylor1{N,T}, b::S) where {N, T<:NumberNotSeries, S<:NumberNotSeries} = +(promote(a,b)...)
232
233
# +(b::S, a::STaylor1{N,T}) where {N, T<:NumberNotSeries, S<:NumberNotSeries} = +(promote(b,a)...)
0 commit comments