diff options
author | Jacques-Henri Jourdan <jacques-henri.jourdan@normalesup.org> | 2019-07-06 16:16:20 +0200 |
---|---|---|
committer | Xavier Leroy <xavierleroy@users.noreply.github.com> | 2019-07-06 16:16:20 +0200 |
commit | 415c5a5a28ac7035cfa33e5753af841a450bfab0 (patch) | |
tree | ef38884d5d3a2a4207d481b32ac7d898859bb04d /MenhirLib/Validator_classes.v | |
parent | 5e8cac37b13cd3dcfbbe8e9dd939ed1fa9d5e310 (diff) | |
download | compcert-415c5a5a28ac7035cfa33e5753af841a450bfab0.tar.gz compcert-415c5a5a28ac7035cfa33e5753af841a450bfab0.zip |
Fix compatibility with Coq 8.10 (#303)
The generation of some fresh names changes in Coq 8.10 (https://github.com/coq/coq/pull/9160).
The `Hint Mode` declaration that does not specify a hint database now triggers a warning.
Specify the intended database and fix the "auto" tactics accordingly.
Diffstat (limited to 'MenhirLib/Validator_classes.v')
-rw-r--r-- | MenhirLib/Validator_classes.v | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/MenhirLib/Validator_classes.v b/MenhirLib/Validator_classes.v index c043cb73..d8063123 100644 --- a/MenhirLib/Validator_classes.v +++ b/MenhirLib/Validator_classes.v @@ -17,7 +17,7 @@ Require Import Alphabet. Class IsValidator (P : Prop) (b : bool) := is_validator : b = true -> P. -Hint Mode IsValidator + -. +Hint Mode IsValidator + - : typeclass_instances. Instance is_validator_true : IsValidator True true. Proof. done. Qed. @@ -31,7 +31,7 @@ Proof. done. Qed. Instance is_validator_and P1 b1 P2 b2 `{IsValidator P1 b1} `{IsValidator P2 b2}: IsValidator (P1 /\ P2) (if b1 then b2 else false). -Proof. split; destruct b1, b2; auto using is_validator. Qed. +Proof. by split; destruct b1, b2; apply is_validator. Qed. Instance is_validator_comparable_leibniz_eq A (C:Comparable A) (x y : A) : ComparableLeibnizEq C -> @@ -49,9 +49,10 @@ Lemma is_validator_forall_finite A P b `(Finite A) : (forall (x : A), IsValidator (P x) (b x)) -> IsValidator (forall (x : A), P x) (forallb b all_list). Proof. - move=> ? /forallb_forall. - auto using all_list_forall, is_validator, forallb_forall. + move=> ? /forallb_forall Hb ?. + apply is_validator, Hb, all_list_forall. Qed. + (* We do not use an instance directly here, because we need somehow to force Coq to instantiate b with a lambda. *) Hint Extern 2 (IsValidator (forall x : ?A, _) _) => |