Type domain (static) integers

I don’t have much to add but was reading through a bit of Static.jl and saw this, in case people find it relevant.

@nsajko said “having [type domain integers] outside of Base means it’s not available for improving Base, not without type piracy”.

Static.jl has this:

const IntType = Union{StaticInt, Int}
IntType(x::Integer) = Int(x)

Union{StaticInt, Int} is an instance of Type{Union{StaticInt, Int}}, which does not “belong to” Static.jl even if StaticInt does. Integer doesn’t belong to Static.jl. I could be wrong, but I think IntType(x::Integer) = Int(x) constitutes type piracy. Previous discussion here: Is dispatch on another type's parameter (::NotMyType{MyType}) piracy?