summaryrefslogtreecommitdiff
path: root/theories/Classes/Init.v
diff options
context:
space:
mode:
authorGravatar Stephane Glondu <steph@glondu.net>2009-02-01 00:54:40 +0100
committerGravatar Stephane Glondu <steph@glondu.net>2009-02-01 00:54:40 +0100
commitcfbfe13f5b515ae2e3c6cdd97e2ccee03bc26e56 (patch)
treeb7832bd5d412a5a5d69cb36ae2ded62c71124c22 /theories/Classes/Init.v
parent113b703a695acbe31ac6dd6a8c4aa94f6fda7545 (diff)
Imported Upstream version 8.2~rc2+dfsgupstream/8.2.rc2+dfsg
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