type.match_duplicate_pattern
Match pattern is already covered.
Area 3, Logic; not declinable; the next step is usually the agent's.
function describe(state: DeliveryState) -> Label { return match state { DeliveryState.pending -> "Pending" DeliveryState.pending -> "Waiting" DeliveryState.sent -> "Sent" DeliveryState.failed -> "Failed" }}
error DeliveryState.pending is matched twice
--> main.jadpo:4:9
|3 | DeliveryState.pending -> "Pending" | --------------------- first matched here4 | 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
Markdown for agents: /docs/errors/type.match_duplicate_pattern.md.Built from Jadpo main at aee2e8f.