From 57f483c72f57e5a01fd1509445a08cf1de6e03bc Mon Sep 17 00:00:00 2001 From: Bourgerie Quentin Date: Thu, 26 Jan 2012 12:30:43 +0100 Subject: [PATCH] [fix] compiler, renaming: ObjectOpaMapToIdent should save only the (package) exported ident --- passes/surfaceAstRenaming.ml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/passes/surfaceAstRenaming.ml b/passes/surfaceAstRenaming.ml index 1abfefc3..4c328110 100644 --- a/passes/surfaceAstRenaming.ml +++ b/passes/surfaceAstRenaming.ml @@ -1819,9 +1819,13 @@ let save_env env = (* only saving the local maptoident for the stdlib packages *) env.maptoident_val, env.maptoident_typ in - ObjectOpaMapToIdent.save (val_,typ); OpaMapToIdent.set_val_map val_; - OpaMapToIdent.set_typ_map typ + OpaMapToIdent.set_typ_map typ; + let val_ = + let filter i = is_exported i all_env.f.fglobal in + StringMap.filter_val filter val_ + in + ObjectOpaMapToIdent.save (val_,typ) let load_expr_env all_env map = let tnames =