aboutsummaryrefslogtreecommitdiffhomepage
path: root/plugins
diff options
context:
space:
mode:
authorGravatar ppedrot <ppedrot@85f007b7-540e-0410-9357-904b9bb8a0f7>2013-09-18 18:29:40 +0000
committerGravatar ppedrot <ppedrot@85f007b7-540e-0410-9357-904b9bb8a0f7>2013-09-18 18:29:40 +0000
commit33eea163c72c70eaa3bf76506c1d07a8cde911fd (patch)
tree69eb4394fc0eb748fa16609e86dbf941234157d8 /plugins
parent71a9b7f264721b8afe5081bb0e13bcf8759d8403 (diff)
At least made the evar type opaque! There are still 5 remaining unsafe
casts of ints to evars. - 2 in Evarutil and Goal which are really needed, even though the Goal one could (and should) be removed; - 2 in G_xml and Detyping that are there for completeness sake, but that might be made anomalies altogether; - 1 in Newring which is quite dubious at best, and should be fixed. git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@16786 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'plugins')
-rw-r--r--plugins/setoid_ring/newring.ml47
-rw-r--r--plugins/xml/acic2Xml.ml42
2 files changed, 6 insertions, 3 deletions
diff --git a/plugins/setoid_ring/newring.ml4 b/plugins/setoid_ring/newring.ml4
index 355a18005..f16c298af 100644
--- a/plugins/setoid_ring/newring.ml4
+++ b/plugins/setoid_ring/newring.ml4
@@ -35,10 +35,13 @@ open Misctypes
(****************************************************************************)
(* controlled reduction *)
-let mark_arg i c = mkEvar(i,[|c|])
+(** ppedrot: something dubious here, we're obviously using evars the wrong
+ way. FIXME! *)
+
+let mark_arg i c = mkEvar(Evar.unsafe_of_int i,[|c|])
let unmark_arg f c =
match destEvar c with
- | (i,[|c|]) -> f i c
+ | (i,[|c|]) -> f (Evar.repr i) c
| _ -> assert false
type protect_flag = Eval|Prot|Rec
diff --git a/plugins/xml/acic2Xml.ml4 b/plugins/xml/acic2Xml.ml4
index 9d3a10dba..73f113d6a 100644
--- a/plugins/xml/acic2Xml.ml4
+++ b/plugins/xml/acic2Xml.ml4
@@ -26,7 +26,7 @@ let rec find_last_id =
| _::tl -> find_last_id tl
;;
-let export_existential = string_of_int
+let export_existential ev = string_of_int (Evar.repr ev)
let print_term ids_to_inner_sorts =
let rec aux =