got rid of "axclass", apparently
authorblanchet
Wed, 24 Feb 2010 09:59:54 +0100
changeset 35338 38848da259c0
parent 35337 48e23510a3d8
child 35339 34819133c75e
got rid of "axclass", apparently
src/HOL/Nitpick_Examples/Refute_Nits.thy
src/HOL/Tools/Nitpick/HISTORY
--- a/src/HOL/Nitpick_Examples/Refute_Nits.thy	Wed Feb 24 09:19:21 2010 +0100
+++ b/src/HOL/Nitpick_Examples/Refute_Nits.thy	Wed Feb 24 09:59:54 2010 +0100
@@ -1381,25 +1381,16 @@
 
 text {* A type class without axioms: *}
 
-axclass classA
+class classA
 
 lemma "P (x\<Colon>'a\<Colon>classA)"
 nitpick [expect = genuine]
 oops
 
-text {* The axiom of this type class does not contain any type variables: *}
-
-axclass classB
-classB_ax: "P \<or> \<not> P"
-
-lemma "P (x\<Colon>'a\<Colon>classB)"
-nitpick [expect = genuine]
-oops
-
 text {* An axiom with a type variable (denoting types which have at least two elements): *}
 
-axclass classC < type
-classC_ax: "\<exists>x y. x \<noteq> y"
+class classC =
+  assumes classC_ax: "\<exists>x y. x \<noteq> y"
 
 lemma "P (x\<Colon>'a\<Colon>classC)"
 nitpick [expect = genuine]
@@ -1411,11 +1402,9 @@
 
 text {* A type class for which a constant is defined: *}
 
-consts
-classD_const :: "'a \<Rightarrow> 'a"
-
-axclass classD < type
-classD_ax: "classD_const (classD_const x) = classD_const x"
+class classD =
+  fixes classD_const :: "'a \<Rightarrow> 'a"
+  assumes classD_ax: "classD_const (classD_const x) = classD_const x"
 
 lemma "P (x\<Colon>'a\<Colon>classD)"
 nitpick [expect = genuine]
@@ -1423,7 +1412,7 @@
 
 text {* A type class with multiple superclasses: *}
 
-axclass classE < classC, classD
+class classE = classC + classD
 
 lemma "P (x\<Colon>'a\<Colon>classE)"
 nitpick [expect = genuine]
--- a/src/HOL/Tools/Nitpick/HISTORY	Wed Feb 24 09:19:21 2010 +0100
+++ b/src/HOL/Tools/Nitpick/HISTORY	Wed Feb 24 09:59:54 2010 +0100
@@ -2,6 +2,8 @@
 
   * Added and implemented "binary_ints" and "bits" options
   * Added "std" option and implemented support for nonstandard models
+  * Added support for local definitions
+  * Optimized "Multiset.multiset"
   * Fixed soundness bugs related to "destroy_constrs" optimization and record
     getters
   * Renamed "MiniSatJNI", "zChaffJNI", "BerkMinAlloy", and "SAT4JLight" to