diff options
| author | Matthieu Sozeau | 2016-03-14 11:16:19 +0100 |
|---|---|---|
| committer | Matthieu Sozeau | 2016-06-16 18:21:08 +0200 |
| commit | d4a421e57d74d305a797897f43ce216fb4c39719 (patch) | |
| tree | e1f8d60abddc2b4d93844b7fca8400380e268f95 /theories/Numbers/Rational/SpecViaQ/QSig.v | |
| parent | 0767b8eace843ee45f2f3fc2b80a13ce6ed336c7 (diff) | |
Typeclasses: stdlib fixes for new search algorithm
Diffstat (limited to 'theories/Numbers/Rational/SpecViaQ/QSig.v')
| -rw-r--r-- | theories/Numbers/Rational/SpecViaQ/QSig.v | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/theories/Numbers/Rational/SpecViaQ/QSig.v b/theories/Numbers/Rational/SpecViaQ/QSig.v index a40d940598..8e20fd0608 100644 --- a/theories/Numbers/Rational/SpecViaQ/QSig.v +++ b/theories/Numbers/Rational/SpecViaQ/QSig.v @@ -115,7 +115,10 @@ Ltac solve_wd2 := intros x x' Hx y y' Hy; qify; now rewrite Hx, Hy. Local Obligation Tactic := solve_wd2 || solve_wd1. Instance : Measure to_Q. -Instance eq_equiv : Equivalence eq := {}. +Instance eq_equiv : Equivalence eq. +Proof. + change eq with (RelCompFun Qeq to_Q); apply _. +Defined. Program Instance lt_wd : Proper (eq==>eq==>iff) lt. Program Instance le_wd : Proper (eq==>eq==>iff) le. @@ -141,7 +144,10 @@ Proof. intros. qify. destruct (Qcompare_spec [x] [y]); auto. Qed. (** Let's implement [TotalOrder] *) Definition lt_compat := lt_wd. -Instance lt_strorder : StrictOrder lt := {}. +Instance lt_strorder : StrictOrder lt. +Proof. + change lt with (RelCompFun Qlt to_Q); apply _. +Qed. Lemma le_lteq : forall x y, x<=y <-> x<y \/ x==y. Proof. intros. qify. apply Qle_lteq. Qed. |
