Wed, 22 Apr 2009 18:03:42 +0100
util.set: Add set.xor() to get a set consisting of items not in both sets
--- a/util/set.lua Wed Apr 22 18:03:02 2009 +0100 +++ b/util/set.lua Wed Apr 22 18:03:42 2009 +0100 @@ -141,4 +141,8 @@ return set; end +function xor(set1, set2) + return union(set1, set2) - intersection(set1, set2); +end + return _M;