> For the complete documentation index, see [llms.txt](https://docs.sannybuilder.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sannybuilder.com/troubleshooting/errors/0107.md).

# 0107: Expected function return type

Compiler expected a valid identifier to follow a colon (`:`) in the [function](/language/functions.md) signature but found something else.

E.g. consider this example:

```pascal
function bar():
```

The function definition ends with a colon implying a return type, but there is none defined. Or:

```pascal
function bar(): 5
```

Compiler found an integer literal, where a name of the type was expected.

#### Possible solutions:

* add one of the known [types](/language/functions.md#signature) after the colon:

```pascal
function bar(): int
```

* if function returns nothing, delete `:` after arguments list

```pascal
function bar()
```
