From: Claudio Sacerdoti Coen Date: Wed, 24 Oct 2007 14:40:47 +0000 (+0000) Subject: Debugging code improved. X-Git-Tag: 0.4.95@7852~107 X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;h=c4ac9504252a463c1250a9cfa458fcb455c73478;p=helm.git Debugging code improved. --- diff --git a/components/grafite_parser/grafiteDisambiguator.ml b/components/grafite_parser/grafiteDisambiguator.ml index fc2cbc74e..8827e709b 100644 --- a/components/grafite_parser/grafiteDisambiguator.ml +++ b/components/grafite_parser/grafiteDisambiguator.ml @@ -27,6 +27,10 @@ open Printf +let debug = false;; +let debug_print s = + if debug then prerr_endline (Lazy.force s);; + exception Ambiguous_input (* the integer is an offset to be added to each location *) exception DisambiguationError of @@ -119,7 +123,7 @@ let disambiguate_thing ~aliases ~universe drop_aliases_and_clear_diff res in let rec aux i errors passes = -(*prerr_endline ("Pass: " ^ string_of_int i);*) + debug_print (lazy ("Pass: " ^ string_of_int i)); match passes with [ pass ] -> (try