Skip to content

Commit 774d7c2

Browse files
committed
Remove short-circuiting in coefficients(Fun, space)
1 parent 5b6c8d0 commit 774d7c2

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

src/Fun.jl

+1-9
Original file line numberDiff line numberDiff line change
@@ -107,15 +107,7 @@ julia> coefficients(f, Legendre()) ≈ [0, 0, 1]
107107
true
108108
```
109109
"""
110-
function coefficients(f::Fun,msp::Space)
111-
#zero can always be converted
112-
fc = f.coefficients
113-
if ncoefficients(f) == 0 || (ncoefficients(f) == 1 && fc[1] == 0)
114-
convert(Vector, fc)
115-
else
116-
coefficients(fc, space(f), msp)
117-
end
118-
end
110+
coefficients(f::Fun, msp::Space) = coefficients(coefficients(f), space(f), msp)
119111
coefficients(f::Fun,::Type{T}) where {T<:Space} = coefficients(f,T(domain(f)))
120112

121113
"""

0 commit comments

Comments
 (0)