X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;ds=sidebyside;f=helm%2Focaml%2Fcic_notation%2Ftest_parser.ml;h=ce87368bf7ae54e8e937db11cbec27a37ba0caa9;hb=08791e80816548121e81e04d3ead8c9a5171d033;hp=0ff7c558e119e3435d461e382998e727d5cbe1e0;hpb=256ea270b884864d0eddd1de66bae2a2cbc513ff;p=helm.git diff --git a/helm/ocaml/cic_notation/test_parser.ml b/helm/ocaml/cic_notation/test_parser.ml index 0ff7c558e..ce87368bf 100644 --- a/helm/ocaml/cic_notation/test_parser.ml +++ b/helm/ocaml/cic_notation/test_parser.ml @@ -41,8 +41,7 @@ let dump_xml t id_to_uri fname = print_endline (sprintf "dumping MathML to %s ..." fname); flush stdout; let oc = open_out fname in - let markup = CicNotationPres.render id_to_uri t in - Xml.pp_to_outchan (xml_stream_of_markup markup) oc; + Xml.pp_to_outchan (CicNotationPres.render_to_boxml id_to_uri t) oc; close_out oc let _ = @@ -108,17 +107,16 @@ let _ = CicNotationRew.ast_of_acic id_to_sort annterm in let time2 = Unix.gettimeofday () in - printf "ast creation took %f seconds\n" (time2 -. time1); - prerr_endline "===="; - print_endline (CicNotationPp.pp_term t); flush stdout; + prerr_endline (sprintf "ast creation took %f seconds\n" (time2 -. time1)); + prerr_endline "AST"; + prerr_endline (CicNotationPp.pp_term t); flush stdout; let time3 = Unix.gettimeofday () in let t' = CicNotationRew.pp_ast t in let time4 = Unix.gettimeofday () in - printf "pretty printing took %f seconds\n" (time4 -. time3); - dump_xml t id_to_uri "out.xml"; - print_endline (CicNotationPp.pp_term t'); flush stdout - ) + prerr_endline (sprintf "pretty printing took %f seconds\n" (time4 -. time3)); + prerr_endline (CicNotationPp.pp_term t'); + dump_xml t' id_to_uri "out.xml") (* CicNotationParser.print_l2_pattern ()) *) | 1 -> ignore (CicNotationParser.parse_syntax_pattern istream) | 2 ->