aboutsummaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorPierre Roux2018-10-19 13:16:25 +0200
committerPierre Roux2019-04-01 22:17:41 +0200
commit1c8fd0f7134bcc295e31613c981ef4ef2c21af35 (patch)
tree8fb25126d146fa57793bb9ba9e1595d0bcfc60a0 /plugins
parent424c1973e96dfbf3b2e3245d735853ffa9600373 (diff)
Replace type sign = bool with SPlus | SMinus
Diffstat (limited to 'plugins')
-rw-r--r--plugins/ltac/g_tactic.mlg3
-rw-r--r--plugins/ssr/ssrparser.mlg4
2 files changed, 4 insertions, 3 deletions
diff --git a/plugins/ltac/g_tactic.mlg b/plugins/ltac/g_tactic.mlg
index 7bf705ffeb..574e22d50e 100644
--- a/plugins/ltac/g_tactic.mlg
+++ b/plugins/ltac/g_tactic.mlg
@@ -147,7 +147,8 @@ let destruction_arg_of_constr (c,lbind as clbind) = match lbind with
end
| _ -> ElimOnConstr clbind
-let mkNumeral n = Numeral (string_of_int (abs n), 0<=n)
+let mkNumeral n =
+ Numeral ((if 0<=n then SPlus else SMinus),string_of_int (abs n))
let mkTacCase with_evar = function
| [(clear,ElimOnConstr cl),(None,None),None],None ->
diff --git a/plugins/ssr/ssrparser.mlg b/plugins/ssr/ssrparser.mlg
index 0ec5f1673a..9931305832 100644
--- a/plugins/ssr/ssrparser.mlg
+++ b/plugins/ssr/ssrparser.mlg
@@ -360,8 +360,8 @@ let interp_index ist gl idx =
| Some c ->
let rc = Detyping.detype Detyping.Now false Id.Set.empty (pf_env gl) (project gl) c in
begin match Notation.uninterp_prim_token rc with
- | _, Constrexpr.Numeral (s,b) ->
- let n = int_of_string s in if b then n else -n
+ | _, Constrexpr.Numeral (b,s) ->
+ let n = int_of_string s in (match b with SPlus -> n | SMinus -> -n)
| _ -> raise Not_found
end
| None -> raise Not_found