From 7d4261aebf12e71e12e0224df23c59394e442b39 Mon Sep 17 00:00:00 2001 From: gareuselesinge Date: Sun, 14 Oct 2012 15:06:18 +0000 Subject: When loading a plugin, prefer .cma to .cmo Imagine foo.cma contains foo_utils.cmo and foo.cmo. Also imagine that foo.cmo depends on foo_utils.cmo. With this patch, when asked to load foo, Coq loads the foo.cma archive. Loading simply foo.cmo would fail since foo_utils.cmo is needed to load foo.cmo. git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@15883 85f007b7-540e-0410-9357-904b9bb8a0f7 --- toplevel/mltop.ml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'toplevel/mltop.ml') diff --git a/toplevel/mltop.ml b/toplevel/mltop.ml index 2ca3a4cd7..9987de85a 100644 --- a/toplevel/mltop.ml +++ b/toplevel/mltop.ml @@ -204,11 +204,11 @@ let file_of_name name = if full then if is_in_path !coq_mlpath_copy base then base else fail base else - let name = base ^ ".cmo" in + let name = base ^ ".cma" in if is_in_path !coq_mlpath_copy name then name else - let name = base ^ ".cma" in + let name = base ^ ".cmo" in if is_in_path !coq_mlpath_copy name then name else - fail (base ^ ".cm[oa]") + fail (base ^ ".cm[ao]") (** Is the ML code of the standard library placed into loadable plugins or statically compiled into coqtop ? For the moment this choice is -- cgit v1.2.3