From: Stefano Zacchiroli Date: Thu, 1 Jun 2006 10:52:11 +0000 (+0000) Subject: use the appropriate chain of transormations for pretty printing term X-Git-Tag: make_still_working~7264 X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;h=55b7e104ed4b153fdbffdc3b4284313b3f18c571;hp=c50e53d7823a04b65233c61f738c2b5caa0dcf6f;p=helm.git use the appropriate chain of transormations for pretty printing term --- diff --git a/helm/software/components/binaries/tptp2grafite/main.ml b/helm/software/components/binaries/tptp2grafite/main.ml index 4042d92d1..3c7d5f934 100644 --- a/helm/software/components/binaries/tptp2grafite/main.ml +++ b/helm/software/components/binaries/tptp2grafite/main.ml @@ -283,8 +283,18 @@ let _ = ([],[]) statements in let pp t = - (* for a correct pp we should disambiguate the term... *) - let term_pp = CicNotationPp.pp_term in + (* ZACK: setting width to 80 will trigger a bug of BoxPp.render_to_string + * which will show up using the following command line: + * ./tptp2grafite -tptppath ~tassi/TPTP-v3.1.1 GRP170-1 *) + let width = max_int in + let term_pp content_term = + let pres_term = TermContentPres.pp_ast content_term in + let dummy_tbl = Hashtbl.create 1 in + let markup = CicNotationPres.render dummy_tbl pres_term in + let s = BoxPp.render_to_string width markup in + s + in + CicNotationPp.set_pp_term term_pp; let lazy_term_pp = fun x -> assert false in let obj_pp = CicNotationPp.pp_obj in print_endline