Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Dial back msubset and msuperset to only work on Baggy objects.

  • Loading branch information...
commit e52d6c3337511923c02b9dd8ae8f9d216c5add14 1 parent 556574c
@colomon colomon authored
Showing with 2 additions and 4 deletions.
  1. +2 −4 lib/CORE.setting
View
6 lib/CORE.setting
@@ -2256,12 +2256,10 @@ multi sub infix:<⊎>(Bag $a, Bag $b --> Bag) { bag((set($a) ∪ set($b)).map({
only sub infix:<(+)>($a, $b --> Bag) is equiv(&infix:<X>) { $a ⊎ $b }
proto sub infix:<≼>($, $ --> Bool) is equiv(&infix:<==>) {*}
-multi sub infix:<≼>(Any $a, Any $b --> Bool) { bag($a) ≼ bag($b) }
-multi sub infix:<≼>(Bag $a, Bag $b --> Bool) { so all $a.keys.map({ $a{$_} <= $b{$_} }) }
+multi sub infix:<≼>(Baggy $a, Baggy $b --> Bool) { so all $a.keys.map({ $a{$_} <= $b{$_} }) }
proto sub infix:<≽>($, $ --> Bool) is equiv(&infix:<==>) {*}
-multi sub infix:<≽>(Any $a, Any $b --> Bool) { bag($a) ≽ bag($b) }
-multi sub infix:<≽>(Bag $a, Bag $b --> Bool) { so all $b.keys.map({ $b{$_} <= $a{$_} }) }
+multi sub infix:<≽>(Baggy $a, Baggy $b --> Bool) { so all $b.keys.map({ $b{$_} <= $a{$_} }) }
class KeyBag does Associative does Baggy {
has Int %!elems; # should be UInt
Please sign in to comment.
Something went wrong with that request. Please try again.