We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 72a705f commit dc49a75Copy full SHA for dc49a75
src/IntervalSets.jl
@@ -63,7 +63,15 @@ isopenset(d::AbstractInterval) = isleftopen(d) && isrightopen(d)
63
64
boundstype(i::AbstractInterval) = boundstype(typeof(i))
65
boundstype(::Type{I}) where {I<:AbstractInterval{T}} where T = T
66
-@deprecate Base.eltype(I::Type{<:AbstractInterval}) boundstype(I) false
+
67
+@static if VERSION < v"1.9"
68
+ function Base.eltype(I::Type{<:AbstractInterval})
69
+ Base.depwarn("`eltype` for `AbstractInterval` will be replaced with `boundstype` in the next breaking release (v0.8.0).", :eltype)
70
+ boundstype(I)
71
+ end
72
+else
73
+ @deprecate Base.eltype(I::Type{<:AbstractInterval}) boundstype(I) false
74
+end
75
76
convert(::Type{AbstractInterval}, i::AbstractInterval) = i
77
convert(::Type{AbstractInterval{T}}, i::AbstractInterval{T}) where T = i
0 commit comments