let rec map is_equal f b =
try
(match d_interp b with
| Sym.Create, [a] ->
let a' = map is_equal f a in
if a == a' then b else
mk_create a'
| Sym.Update, [a; i; x] ->
let a' = map is_equal f a
and i' = map is_equal f i
and x' = map is_equal f x in
if a == a' && i == i' && x == x' then b else
mk_update is_equal a' i' x'
| Sym.Select, [a; j] ->
let a' = map is_equal f a
and j' = map is_equal f j in
if a == a' && j == j' then b else
mk_select is_equal a' j'
| _ ->
f b)
with
Not_found -> f b