@@ -645,9 +645,9 @@ message KindCheckError {
645645
646646 // Unbound type reference ty_ref detected in term ty_def.
647647 message UnboundTyRefError {
648- TyDef ty_def = 1 ;
649- TyRef ty_ref = 2 ;
650- ModuleName module_name = 3 ;
648+ ModuleName module_name = 1 ;
649+ TyDef ty_def = 2 ;
650+ TyRef ty_ref = 3 ;
651651 }
652652
653653 // In ty_def an error has occurred when trying to unify kind ty_kind_lhs
@@ -656,35 +656,34 @@ message KindCheckError {
656656 // FIXME(cstml): Add source of constraint to the error such that user can see
657657 // where the constraint was generated - therefore where the error precisely
658658 // is.
659- message ImpossibleUnificationError {
660- TyDef ty_def = 1 ;
661- Kind ty_kind_lhs = 2 ;
662- Kind ty_kind_rhs = 3 ;
663- ModuleName module_name = 4 ;
659+ message UnificationError {
660+ ModuleName module_name = 1 ;
661+ TyDef ty_def = 2 ;
662+ Kind ty_kind_lhs = 3 ;
663+ Kind ty_kind_rhs = 4 ;
664664 }
665665
666- // A cyclic term was encountered. Infinite terms like this are not acceptable,
667- // and we do not support them. We could not construct infinite "a = ty_name a"
668- // error.
669- message RecursiveKindError {
666+ // A cyclic kind was encountered. Infinite kinds like this are not acceptable,
667+ // and we do not support them. We could not construct infinite kind in ty_def.
668+ message CyclicKindError {
670669 TyDef ty_def = 1 ;
671670 ModuleName module_name = 2 ;
672671 }
673672
674673 // The actual_kind differs from the expected_kind.
675674 message InconsistentTypeError {
676- TyDef ty_def = 1 ;
677- Kind actual_kind = 2 ;
678- Kind expected_kind = 3 ;
679- ModuleName module_name = 4 ;
675+ ModuleName module_name = 1 ;
676+ TyDef ty_def = 2 ;
677+ Kind actual_kind = 3 ;
678+ Kind expected_kind = 4 ;
680679 }
681680
682681 // One of the errors occurred during kind checking.
683682 oneof kind_check_error {
684683 UnboundTyRefError unbound_ty_ref_error = 1 ;
685684 UnboundTyVarError unbound_ty_var_error = 2 ;
686- ImpossibleUnificationError impossible_unification_error = 3 ;
687- RecursiveKindError recursive_kind_error = 4 ;
685+ UnificationError unification_error = 3 ;
686+ CyclicKindError cyclic_kind_error = 4 ;
688687 InconsistentTypeError inconsistent_type_error = 5 ;
689688 }
690689}
0 commit comments