Set.st
changeset 6519 0917c895b86c
parent 6233 0a79cbd07543
child 6540 cf1a6a1a8645
--- a/Set.st	Thu May 02 11:18:55 2002 +0200
+++ b/Set.st	Thu May 02 11:19:23 2002 +0200
@@ -957,6 +957,22 @@
 
 !Set methodsFor:'set operations'!
 
++ aCollection
+    "return a new set containing all elements of the receiver 
+     plus those of the argument collection"
+
+    |newCollection|
+
+    newCollection := self species new.
+    newCollection addAll:self.
+    newCollection addAll:aCollection.
+    ^ newCollection
+
+    "
+     #(0 2 4 6 8) asSet + #(1 3 5 7)   
+    "
+!
+
 - aCollection
     "return a new set containing all elements of the receiver, which are
      NOT also contained in the argument collection"
@@ -1107,6 +1123,6 @@
 !Set class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/Set.st,v 1.75 2001-11-23 10:12:57 martin Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/Set.st,v 1.76 2002-05-02 09:19:23 cg Exp $'
 ! !
 Set initialize!