Definition var_env_or (ve1 ve2 : var_env) (x : ad) := ve1 x || ve2 x.
Definition var_env'_or (ve1 ve2 : var_env') (x : nat) := ve1 x || ve2 x.

Lemma renamef_ext :
forall (be : bool_expr) (f g : ad -> ad),
(forall x : ad, f x = g x) -> renamef f be = renamef g be.