let levels ppf elev =
                  let _ =
                    List.fold_left
                      (fun sep lev ->
                         let rules =
                           (List.map (fun t -> Sself :: t)
                              (flatten_tree lev.lsuffix))
                             @ (flatten_tree lev.lprefix)
                         in
                           (fprintf ppf "%t@[<hov 2>" sep;
                            (match lev.lname with
                             | Some n -> fprintf ppf "%S@;<1 2>" n
                             | None -> ());
                            (match lev.assoc with
                             | LeftA -> fprintf ppf "LEFTA"
                             | RightA -> fprintf ppf "RIGHTA"
                             | NonA -> fprintf ppf "NONA");
                            fprintf ppf "@]@;<1 2>";
                            print_level ppf pp_force_newline rules;
                            fun ppf -> fprintf ppf "@,| "))
                      (fun _ -> ()) elev
                  in ()