# E4201

Compiler diagnostic name: `struct_constr_inconsistent_impl`.

The implementation of a struct constructor must have the same parameter and
return types as the constructor declaration in the `struct`. A method with a
different signature is not an implementation of that constructor.

## Erroneous example

```{literalinclude} /sources/error_codes/4201_error/top.mbt
:language: moonbit
```

## Suggestion

Change either the constructor declaration or the `Type::new` implementation so
their signatures match.

```{literalinclude} /sources/error_codes/4201_fixed/top.mbt
:language: moonbit
```
