--- a/Collection.st Tue Nov 03 20:52:57 2009 +0100
+++ b/Collection.st Tue Nov 03 21:02:27 2009 +0100
@@ -3211,6 +3211,23 @@
"
!
+symmetricDifference:aCollection
+ "return a new set containing all elements,
+ which are contained in either the receiver or aCollection, but not in both.
+ Same as xor: - for compatibility"
+
+ ^ self xor:aCollection
+
+ "
+ |c1 c2|
+
+ c1 := #( foo bar baz baloo ).
+ c2 := #( foe bar banana baloo ).
+ c1 symmetricDifference:c2.
+ self assert:(c1 symmetricDifference:c2) asSet = (c2 symmetricDifference:c1) asSet
+ "
+!
+
union:aCollection
"return a new set containing all elements of the receiver
plus those of the aCollection"
@@ -3591,11 +3608,11 @@
!Collection class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libbasic/Collection.st,v 1.235 2009-10-26 15:01:56 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libbasic/Collection.st,v 1.236 2009-11-03 20:02:27 cg Exp $'
!
version_CVS
- ^ '$Header: /cvs/stx/stx/libbasic/Collection.st,v 1.235 2009-10-26 15:01:56 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libbasic/Collection.st,v 1.236 2009-11-03 20:02:27 cg Exp $'
! !
Collection initialize!