summaryrefslogtreecommitdiff
path: root/theories/Classes/Init.v
diff options
context:
space:
mode:
Diffstat (limited to 'theories/Classes/Init.v')
-rw-r--r--theories/Classes/Init.v14
1 files changed, 10 insertions, 4 deletions
diff --git a/theories/Classes/Init.v b/theories/Classes/Init.v
index e5f951d0..5df7a4ed 100644
--- a/theories/Classes/Init.v
+++ b/theories/Classes/Init.v
@@ -13,12 +13,18 @@
Institution: LRI, CNRS UMR 8623 - UniversitÃcopyright Paris Sud
91405 Orsay, France *)
-(* $Id: Init.v 11282 2008-07-28 11:51:53Z msozeau $ *)
+(* $Id: Init.v 11709 2008-12-20 11:42:15Z msozeau $ *)
(* Ltac typeclass_instantiation := typeclasses eauto || eauto. *)
Tactic Notation "clapply" ident(c) :=
- eapply @c ; eauto with typeclass_instances.
+ eapply @c ; typeclasses eauto.
+
+(** Hints for the proof search: these combinators should be considered rigid. *)
+
+Require Import Coq.Program.Basics.
+
+Typeclasses Opaque id const flip compose arrow impl iff.
(** The unconvertible typeclass, to test that two objects of the same type are
actually different. *)
@@ -27,8 +33,8 @@ Class Unconvertible (A : Type) (a b : A).
Ltac unconvertible :=
match goal with
- | |- @Unconvertible _ ?x ?y => conv x y ; fail 1 "Convertible"
- | |- _ => apply Build_Unconvertible
+ | |- @Unconvertible _ ?x ?y => unify x y with typeclass_instances ; fail 1 "Convertible"
+ | |- _ => eapply Build_Unconvertible
end.
Hint Extern 0 (@Unconvertible _ _ _) => unconvertible : typeclass_instances. \ No newline at end of file