let iter s f x = let rec loop y = f y; try Set.iter loop (Map.find y s.inv) with Not_found -> () in let (y, _) = find s x in loop y