author | wenzelm |
Tue, 08 Feb 1994 14:08:38 +0100 | |
changeset 265 | 443dc2c37583 |
parent 264 | ca6eb7e6e94f |
child 266 | 3fe01df1a614 |
--- a/src/Pure/library.ML Fri Feb 04 10:32:27 1994 +0100 +++ b/src/Pure/library.ML Tue Feb 08 14:08:38 1994 +0100 @@ -439,6 +439,12 @@ fun gen_subset eq (xs, ys) = forall (fn x => gen_mem eq (x, ys)) xs; +(*eq_set*) + +fun eq_set (xs, ys) = + xs = ys orelse (xs subset ys andalso ys subset xs); + + (*removing an element from a list WITHOUT duplicates*) infix \; fun (y :: ys) \ x = if x = y then ys else y :: (ys \ x)