New blog post about Julia parametric types and constructors

we enable the definition of several concrete types like Point{Float64}, Point{Int}, Point{String}, etc., and each of them derive from an ancestor type Point

I think this is not quite correct as Point is not an “ancestor type” as I’d understand it (to me that sounds like an abstract type usually defined with abstract type). It’s a UnionAll and short for Point{T} where T:

julia> struct Point{T}
           x::T
           y::T
       end

julia> isabstracttype(Point)
false

julia> Point{T} where T
Point
2 Likes