E4160

E4160#

Type mismatch with mbti.

When a package implements a virtual package, it is checked against the interface of that virtual package, and this error is emitted if some of the interface has different types.

错误示例#

E4160.mbti#
package "moonbit-community/E4160";

fn f() -> Unit
top.mbt#
///|
pub fn f() -> Int {
  42
}

建议#

Modify the implementation such that it has the exact signature as the virtual package it declared to implement.

///|
pub fn f() -> Unit {

}