From 088b3161c93e46ec2d865fe71a206cee15acd30c Mon Sep 17 00:00:00 2001 From: Pierre Letouzey Date: Thu, 19 May 2016 20:37:23 +0200 Subject: native_compute: don't call Unicode.ascii_of_ident twice (not idempotent anymore) --- kernel/nativecode.ml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'kernel/nativecode.ml') diff --git a/kernel/nativecode.ml b/kernel/nativecode.ml index 9d181b476..2159a702c 100644 --- a/kernel/nativecode.ml +++ b/kernel/nativecode.ml @@ -1487,8 +1487,8 @@ let optimize_stk stk = (** Printing to ocaml **) (* Redefine a bunch of functions in module Names to generate names acceptable to OCaml. *) -let string_of_id s = Unicode.ascii_of_ident (string_of_id s) -let string_of_label l = Unicode.ascii_of_ident (string_of_label l) +let string_of_id s = Unicode.ascii_of_ident (Id.to_string s) +let string_of_label l = string_of_id (Label.to_id l) let string_of_dirpath = function | [] -> "_" @@ -1561,8 +1561,7 @@ let pp_gname fmt g = Format.fprintf fmt "%s" (string_of_gname g) let pp_lname fmt ln = - let s = Unicode.ascii_of_ident (string_of_name ln.lname) in - Format.fprintf fmt "x_%s_%i" s ln.luid + Format.fprintf fmt "x_%s_%i" (string_of_name ln.lname) ln.luid let pp_ldecls fmt ids = let len = Array.length ids in -- cgit v1.2.3