# `syntax.inline_function_arrow`

Inline function written in another language's form.

Area 3, [Logic](../topics/logic.md); not declinable; the next step is usually the agent's.

An inline function is `item -> expression`.

```jadpo
type TodoTitle = Text {
    max_length: 200
}

type Todo = Object {
    title: TodoTitle
}

function titles(todos: List<Todo>) -> List<TodoTitle> {
    return list.map(todos, todo => todo.title)
}
```

```text
error: Jadpo writes `todo -> todo.title`, not `todo => todo.title`
 --> main.jadpo:10:28
   |
10 |     return list.map(todos, todo => todo.title)
   |                            ^^^^^^^ write `todo -> todo.title`
  reason: `x => e` is an arrow function in JavaScript, TypeScript and C#, `lambda x: e` in Python and `|x| e` in Rust; a Jadpo inline function is `item -> expression`.
  next: Write `todo -> todo.title` (agent)
  rule: syntax.inline_function_arrow
  help: https://jadpo.dev/docs/errors/syntax.inline_function_arrow

check failed: 1 error, 1 file
```
