let is_like e functions =
let function_name e =
let rec check_module e =
match e with
ExAcc(_, ExUid(_, _), e) -> check_module e
| ExUid(_, _) -> true
| _ -> false
in
match e with
ExLid(_, s) -> s
| ExAcc(_, e, ExLid(_, s)) when check_module e -> s
| _ -> raise Not_found
in
try
List.mem (function_name e) !functions
with Not_found ->
false