You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Very close to #9441 (open), #6721 (closed), and several related issues.
julia>struct Thing{A<:AbstractUnitRange,B} end
julia>const ThingInt{A} = Thing{A,Int}
Thing{A,Int64} where A
julia> ThingInt <:Thingfalse
julia> ThingInt{<:AbstractUnitRange} <:Thingtrue
yet
julia> ThingInt{Float64}
ERROR: TypeError:in Thing, in A, expected A<:AbstractUnitRange, got Type{Float64}
Where this seems like it could be slightly tricky is something like this:
julia>struct DimsThing{Dims<:Tuple{Vararg{Int}},B} end
julia>const DimsInt{N} = DimsThing{<:NTuple{N},Int}
DimsThing{#s1,Int64} where #s1<:(Tuple{Vararg{T,N}} where T) where N
julia> DimsInt <:DimsThingfalse
However, this too seems pretty easily solved by computing the type intersection of the RHS with the constraints in the type definition.
The text was updated successfully, but these errors were encountered:
Very close to #9441 (open), #6721 (closed), and several related issues.
yet
Where this seems like it could be slightly tricky is something like this:
However, this too seems pretty easily solved by computing the type intersection of the RHS with the constraints in the type definition.
The text was updated successfully, but these errors were encountered: