Explain why exhaustiveness is necessary for soundness

This commit is contained in:
Nadrieril 2020-10-16 22:48:00 +01:00 committed by Joshua Nelson
parent 5ddfd9bfe9
commit d859c9924e
1 changed files with 2 additions and 1 deletions

View File

@ -37,7 +37,8 @@ match x {
Thus usefulness is used for two purposes:
detecting unreachable code (which is useful to the user),
and ensuring that matches are exhaustive (which is important for soundness).
and ensuring that matches are exhaustive (which is important for soundness,
because a match expression can return a value).
## Where it happens