Skip to content

Commit

Permalink
Fix ambiguity in ℵ₀ ≤ RealInfinity() (#16)
Browse files Browse the repository at this point in the history
  • Loading branch information
dlfivefifty authored Sep 9, 2021
1 parent 622c39e commit 4c038b0
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "Infinities"
uuid = "e1ba4f0e-776d-440f-acd9-e1d2e9742647"
authors = ["Sheehan Olver <[email protected]>"]
version = "0.1.1"
version = "0.1.2"

[compat]
julia = "1"
Expand Down
2 changes: 2 additions & 0 deletions src/cardinality.jl
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,8 @@ isless(x::InfiniteCardinal, y::AbstractFloat) = false
<(::InfiniteCardinal, x::Real) = false
(::InfiniteCardinal{0}, x::Real) = x
(::InfiniteCardinal, x::Real) = false
(::InfiniteCardinal{0}, x::RealInfinity) = x
(::InfiniteCardinal, x::RealInfinity) = false
>(::InfiniteCardinal{0}, y::Real) => y
>(::InfiniteCardinal, ::Real) = true
(::InfiniteCardinal, ::Real) = true
Expand Down
3 changes: 3 additions & 0 deletions test/test_cardinality.jl
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ using Infinities, Base64, Base.Checked, Test
@test !(-> ℵ₀) && !(- ℵ₀)
@test ℵ₀ > -
@test ℵ₁ > -&& ℵ₁ -
@test ℵ₀  RealInfinity()
@test !(ℵ₀  -∞)
@test !(ℵ₁  RealInfinity())

@test Inf < ℵ₁ && !(ℵ₁ < Inf)
@test !(Inf < ℵ₀) && !(ℵ₀ < Inf)
Expand Down

2 comments on commit 4c038b0

@dlfivefifty
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/44548

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.1.2 -m "<description of version>" 4c038b053bca91819be77a52565b9594a1c30963
git push origin v0.1.2

Please sign in to comment.