# E4114

Only toplevel functions can have labelled arguments.

This error occurs when trying to use labelled arguments in a local function or
anonymous function.

## Erroneous example

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

## Suggestion

To fix this error, you can either:

- Move the function to the top level of the module

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

- Remove the labelled arguments

```{literalinclude} /sources/error_codes/4114_fixed/top_1.mbt
:language: moonbit
```
