# `type.match_duplicate_pattern`

Match pattern is already covered.

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

```jadpo
function describe(state: DeliveryState) -> Label {
    return match state {
        DeliveryState.pending -> "Pending"
        DeliveryState.pending -> "Waiting"
        DeliveryState.sent -> "Sent"
        DeliveryState.failed -> "Failed"
    }
}
```

```text
error: `DeliveryState.pending` is matched twice
 --> main.jadpo:4:9
  |
3 |         DeliveryState.pending -> "Pending"
  |         --------------------- first matched here
4 |         DeliveryState.pending -> "Waiting"
  |         ^^^^^^^^^^^^^^^^^^^^^ matched again
  reason: Each case is matched once; the first arm takes every value this one would, so this arm never runs.
  next: Remove this arm, or merge its body into the first (agent)
  rule: type.match_duplicate_pattern
  help: https://jadpo.dev/docs/errors/type.match_duplicate_pattern

check failed: 1 error, 2 files
```
