Taking the following example:

type Point{T<:Real}
         x::T
         y::T
end

I can construct a Point taking the type "T" from the argument types.
Or I can explicity specify the type

Point{Int32}(2,2)

But I'd like to be able to specify a default type:

type Point{T<:Real=Int32}

for example, so that an unqualified
Point(2,2)

would produce Point{Int32}, while still allowing explicity
Point{Int64}(2,2)

I don't see a way to do that

Reply via email to