aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Gaëtan Gilbert <gaetan.gilbert@skyskimmer.net>2017-11-19 22:35:52 +0100
committerGravatar Gaëtan Gilbert <gaetan.gilbert@skyskimmer.net>2017-11-19 22:35:52 +0100
commit694584698a3dfcc3912dc6d65d7d670d2d5d2a23 (patch)
tree85a7a0733b79a37b6657ba6f2c6a695f4fac61c1
parentedf1a8f36f75861b822081b3825357e122b6937d (diff)
Fix #5790: make Hint Resolve <- respect univ polymorphism flag.
-rw-r--r--plugins/ltac/extratactics.ml43
-rw-r--r--test-suite/bugs/closed/5790.v7
2 files changed, 9 insertions, 1 deletions
diff --git a/plugins/ltac/extratactics.ml4 b/plugins/ltac/extratactics.ml4
index 4b1555e55..71db919ef 100644
--- a/plugins/ltac/extratactics.ml4
+++ b/plugins/ltac/extratactics.ml4
@@ -315,7 +315,8 @@ let project_hint pri l2r r =
in
let ctx = Evd.universe_context_set sigma in
let c = EConstr.to_constr sigma c in
- let c = Declare.declare_definition ~internal:Declare.InternalTacticRequest id (c,ctx) in
+ let poly = Flags.use_polymorphic_flag () in
+ let c = Declare.declare_definition ~poly ~internal:Declare.InternalTacticRequest id (c,ctx) in
let info = {Vernacexpr.hint_priority = pri; hint_pattern = None} in
(info,false,true,Hints.PathAny, Hints.IsGlobRef (Globnames.ConstRef c))
diff --git a/test-suite/bugs/closed/5790.v b/test-suite/bugs/closed/5790.v
new file mode 100644
index 000000000..6c93a3906
--- /dev/null
+++ b/test-suite/bugs/closed/5790.v
@@ -0,0 +1,7 @@
+Set Universe Polymorphism.
+Section foo.
+Context (v : Type).
+Axiom a : True <-> False.
+
+Hint Resolve -> a.
+End foo.