Skip to content

Commit c67ebb5

Browse files
committed
document for which consts we do exhaustiveness checking
1 parent e8414f1 commit c67ebb5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

patterns.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ Most of the time there are no extra soundness concerns due to const-patterns; ex
2525
However, there is one exception: some constants participate in exhaustiveness checking.
2626
If a pattern is incorrectly considered exhaustive, that leads to a critical soundness bug.
2727

28-
Exhaustiveness checking is done for constants of type TODO, as well as `&[u8]` and `&str` (but no other types with references).
28+
Exhaustiveness checking is done for all constants that do not have reference type, as well as `&[u8]` and `&str`.
2929
This means we can write:
3030
```rust
3131
#![feature(exclusive_range_pattern)]

0 commit comments

Comments
 (0)