Sorts.class_error: produce message only (formerly msg_class_error);
authorwenzelm
Sun, 13 Apr 2008 16:40:08 +0200
changeset 26642 454d11701fa4
parent 26641 cf67665296c2
child 26643 99f5407c05ef
Sorts.class_error: produce message only (formerly msg_class_error);
src/Pure/Isar/class.ML
src/Tools/code/code_funcgr.ML
--- a/src/Pure/Isar/class.ML	Sun Apr 13 16:40:07 2008 +0200
+++ b/src/Pure/Isar/class.ML	Sun Apr 13 16:40:08 2008 +0200
@@ -707,7 +707,7 @@
               (Consts.typargs consts c_ty) sorts)
       | matchings _ = I
     val tvartab = (fold o fold_aterms) matchings ts Vartab.empty
-      handle Sorts.CLASS_ERROR e => Sorts.class_error pp e;
+      handle Sorts.CLASS_ERROR e => error (Sorts.class_error pp e);
     val inst = map_type_tvar (fn (vi, _) => TVar (vi, the (Vartab.lookup tvartab vi)));
   in if Vartab.is_empty tvartab then NONE else SOME ((map o map_types) inst ts) end;
 
--- a/src/Tools/code/code_funcgr.ML	Sun Apr 13 16:40:07 2008 +0200
+++ b/src/Tools/code/code_funcgr.ML	Sun Apr 13 16:40:08 2008 +0200
@@ -115,7 +115,7 @@
             val tys = Sign.const_typargs thy (c, ty);
             val sorts = map (snd o dest_TVar) (Sign.const_typargs thy (c, ty_decl));
           in fn tab => fold2 (curry (Sorts.meet_sort algebra)) tys sorts tab
-            handle Sorts.CLASS_ERROR e => raise CLASS_ERROR ([c], Sorts.msg_class_error pp e ^ ",\n"
+            handle Sorts.CLASS_ERROR e => raise CLASS_ERROR ([c], Sorts.class_error pp e ^ ",\n"
               ^ "for constant " ^ CodeUnit.string_of_const thy c
               ^ "\nin defining equations(s)\n"
               ^ (cat_lines o map string_of_thm) thms)