diff --git a/crates/ailang-core/src/workspace.rs b/crates/ailang-core/src/workspace.rs index 443654f..bef7614 100644 --- a/crates/ailang-core/src/workspace.rs +++ b/crates/ailang-core/src/workspace.rs @@ -200,18 +200,6 @@ pub enum WorkspaceLoadError { method: String, }, - /// Iter 22b.2: an instance specifies a body for a method name - /// that the corresponding class does not declare. Symmetric to - /// `MissingMethod` but in the opposite direction. - #[error( - "instance `{class} {type_repr}` provides body for method `{method}`, but class `{class}` does not declare it" - )] - OverridingNonExistentMethod { - class: String, - type_repr: String, - method: String, - }, - /// Iter 22b.2: class-schema validation. The class parameter /// appears in applied position (e.g. as the head of a /// `Type::Con { name == param, args.len() > 0 }`) inside a method @@ -256,6 +244,18 @@ pub enum WorkspaceLoadError { constraint_class: String, var: String, }, + + /// Iter 22b.2: an instance specifies a body for a method name + /// that the corresponding class does not declare. Symmetric to + /// `MissingMethod` but in the opposite direction. + #[error( + "instance `{class} {type_repr}` provides body for method `{method}`, but class `{class}` does not declare it" + )] + OverridingNonExistentMethod { + class: String, + type_repr: String, + method: String, + }, } /// Hash over the canonical bytes of a complete module.