Skip to content

Commit 655a1a4

Browse files
authored
Fix ⊊, ⊋ on non-Set arguments (#42155)
1 parent 819c45b commit 655a1a4

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

base/abstractset.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -338,8 +338,8 @@ false
338338
"""
339339
,
340340

341-
(a::AbstractSet, b) = length(a) < length(b) && a b
342-
(a, b) = Set(a) b
341+
(a::AbstractSet, b::AbstractSet) = length(a) < length(b) && a b
342+
(a, b) = Set(a) Set(b)
343343
(a, b) = b a
344344

345345
function end

test/sets.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -803,3 +803,8 @@ end
803803
A = empty!(A)
804804
@test isempty(A)
805805
end
806+
807+
@testset "⊊, ⊋" begin
808+
@test !((1, 2) (1, 2, 2))
809+
@test !((1, 2, 2) (1, 2))
810+
end

0 commit comments

Comments
 (0)