# E4065

Overloaded operator should accept the correct number of arguments.

You can refer to the [Operator Overloading](../methods.md#operator-overloading)
section for a list of operators that can be overloaded, and here is a list of
number of arguments that each operator should accept:

| Operator | `#alias` value | Number of Arguments |
|----------|----------------|---------------------|
| `_[_]` | `"_[_]"` | 2 |
| `_[_] = _` | `"_[_]=_"` | 3 |
| `_[_:_]` | `"_[_:_]"` | 3 |

## Erroneous example

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

## Suggestion

Give the aliased method the number of arguments expected by the operator.

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