]> git.lizzy.rs Git - rust.git/blob - src/docs/almost_complete_letter_range.txt
Auto merge of #9425 - kraktus:patch-1, r=xFrednet
[rust.git] / src / docs / almost_complete_letter_range.txt
1 ### What it does
2 Checks for ranges which almost include the entire range of letters from 'a' to 'z', but
3 don't because they're a half open range.
4
5 ### Why is this bad?
6 This (`'a'..'z'`) is almost certainly a typo meant to include all letters.
7
8 ### Example
9 ```
10 let _ = 'a'..'z';
11 ```
12 Use instead:
13 ```
14 let _ = 'a'..='z';
15 ```