aboutsummaryrefslogtreecommitdiffhomepage
path: root/library/declaremods.ml
diff options
context:
space:
mode:
authorGravatar Enrico Tassi <Enrico.Tassi@inria.fr>2014-03-06 13:31:38 +0100
committerGravatar Enrico Tassi <Enrico.Tassi@inria.fr>2014-03-11 11:04:45 +0100
commitb2a6a5390436e6ba27d604d18e3b4c757875afd1 (patch)
treed48466472962ee1df4776db9463a98535dcfedb4 /library/declaremods.ml
parent0cd0a3ecdc7f942da153c59369ca3572bd18dd10 (diff)
vi2vo: universes handling finally fixed
Universes that are computed in the vi2vo step are not part of the outermost module stocked in the vo file. They are part of the Library.seg_univ segment and are hence added to the safe env when the vo file is loaded. The seg_univ has been augmented. It is now: - an array of universe constraints, one for each constant whose opaque body was computed in the vi2vo phase. This is useful only to print the constants (and its associated constraints). - a union of all the constraints that come from proofs generated in the vi2vo phase. This is morally the missing bits in the toplevel module body stocked in the vo file, and is there to ease the loading of a .vo file (obtained from a .vi file). - a boolean, false if the file is incomplete (.vi) and true if it is complete (.vo obtained via vi2vo).
Diffstat (limited to 'library/declaremods.ml')
-rw-r--r--library/declaremods.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/library/declaremods.ml b/library/declaremods.ml
index c60e008d1..2b917587c 100644
--- a/library/declaremods.ml
+++ b/library/declaremods.ml
@@ -849,7 +849,7 @@ type library_values = Nativecode.symbol array
let library_values =
Summary.ref (Dirmap.empty : library_values Dirmap.t) ~name:"LIBVALUES"
-let register_library dir cenv (objs:library_objects) digest =
+let register_library dir cenv (objs:library_objects) digest univ =
let mp = MPfile dir in
let () =
try
@@ -857,7 +857,7 @@ let register_library dir cenv (objs:library_objects) digest =
ignore(Global.lookup_module mp);
with Not_found ->
(* If not, let's do it now ... *)
- let mp', values = Global.import cenv digest in
+ let mp', values = Global.import cenv univ digest in
if not (ModPath.equal mp mp') then
anomaly (Pp.str "Unexpected disk module name");
library_values := Dirmap.add dir values !library_values