Project

General

Profile

Revision 714588bf

View differences:

src/backends/EMF/EMF_common.ml
34 34
    
35 35
(* Basic printing functions *)
36 36

  
37
(* If string length of f is longer than 50 chars, we select the 20 first and
37
(* If string length of f is longer than 50 chars, we select the 10 first and
38 38
   last and put a hash in the middle *)
39 39
let print_protect fmt f =
40 40
  fprintf str_formatter "%t" f;
41 41
  let s = flush_str_formatter () in
42 42
  let l = String.length s in
43
  if l > 50 then
44
    let prefix = String.sub s 0 20 and
45
	suffix = String.sub s (l-20) 20 in
43
  if l > 30 then
44
    let prefix = String.sub s 0 10 and
45
	suffix = String.sub s (l-10) 10 in
46 46
    let hash = Hashtbl.hash s in
47 47
    fprintf fmt "%s_%i_%s" prefix hash suffix
48 48
  else

Also available in: Unified diff