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.
1 parent b739cc7 commit 80e04fdCopy full SHA for 80e04fd
src/intervals.jl
@@ -36,7 +36,6 @@ immutable Interval{T}
36
lo::T
37
hi::T
38
function Interval(lo, hi)
39
- isleaftype(T) || throw(ArgumentError("cannot construct Interval with an abstract type parameter"))
40
lo <= hi ? new(lo, hi) : throw(ArgumentError("lo must be less than or equal to hi"))
41
end
42
test/intervals.jl
@@ -9,7 +9,6 @@
9
v = [1 .. 2, 3.0 .. 4.0]
10
@test v[1] === 1.0 .. 2.0
11
@test v[2] === 3.0 .. 4.0
12
-@test_throws ArgumentError [1 .. 2, Dates.today() .. Dates.today()]
13
14
# Test simple arithmetic, with promotion behaviors
15
@test (1.0 .. 2.0) + 1 === (2.0 .. 3.0)
0 commit comments