+ sanitize_tokens acc (remove_args tl)
+ | (("SYMBOL", "⇒"), _) as hd :: tl ->
+ (* avoid rottening of constructor names in pattern matching *)
+ let rec remove_until_branch_start = function
+ | (("SYMBOL", ("|" | "[")), _) :: tl -> tl
+ | hd :: tl -> remove_until_branch_start tl
+ | [] -> [] in
+ sanitize_tokens (hd :: remove_until_branch_start acc) tl
+ | hd :: tl -> (* every other identfier can be rottened! *)
+ sanitize_tokens (hd :: acc) tl in