On 18 August 2015 at 10:22, Uwe Fechner <uwe.fechner....@gmail.com> wrote:
>
> Ok, the following definition works on Julia 0.4, but not with 0.3:
>
> FloatArray = Union{Array{Float32, 1}, Array{Float64, 1}}
>
> function sum(x::FloatArray).
>
> Any idea?

I would simply go with:

    function mysum{T<:FloatingPoint}(x::Vector{T}) sum(x) end

Reply via email to