We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
eltype(::Type{I}) where {I<:AbstractInterval{T}}
1 parent 031a18d commit 5148556Copy full SHA for 5148556
src/IntervalSets.jl
@@ -63,7 +63,7 @@ isclosedset(d::AbstractInterval) = isleftclosed(d) && isrightclosed(d)
63
isopenset(d::AbstractInterval) = isleftopen(d) && isrightopen(d)
64
65
eltype(::Type{AbstractInterval{T}}) where {T} = T
66
-@pure eltype(::Type{I}) where {I<:AbstractInterval} = eltype(supertype(I))
+eltype(::Type{I}) where {I<:AbstractInterval{T}} where T = T
67
68
convert(::Type{AbstractInterval}, i::AbstractInterval) = i
69
convert(::Type{AbstractInterval{T}}, i::AbstractInterval{T}) where T = i
0 commit comments