type.match_unreachable_pattern
Match arm is unreachable after the wildcard.
Area 3, Logic; not declinable; the next step is usually the agent's.
function shout(label: Label) -> Label { return match label { "" -> "unnamed" _ -> label "quiet" -> "QUIET" }}
error This arm never runs
--> main.jadpo:5:9
|4 | _ -> label | - matches everything left5 | "quiet" -> "QUIET" | ^^^^^^^ after `_`
- reason
_matches every value the arms above it don't, so no arm after it runs.- next
- Move this arm above
_(agent) - rule
- type.
match_ unreachable_ pattern - help
- https://jadpo.
dev/docs/errors/type. match_ unreachable_ pattern
Markdown for agents: /docs/errors/type.match_unreachable_pattern.md.Built from Jadpo main at aee2e8f.