(** Useful tactic for simplifying expressions like [In y (add x (union s s'))] *)
Ltac set_iff :=
repeat (progress (
rewrite add_iff || rewrite remove_iff || rewrite singleton_iff
|| rewrite union_iff || rewrite inter_iff || rewrite diff_iff
|| rewrite empty_iff)).
(**  * Specifications written using boolean predicates *)
Section BoolSpec.
Variable s s' s'' : t.
Variable x y z : elt.

Lemma filter_b : compat_bool E.eq f -> mem x (filter f s) = mem x s && f x.