Skip to content

Commit c0c4525

Browse files
authored
Rollup merge of #150651 - Sekar-C-Mca:fix-pattern-usefulness-typo, r=nnethercote
Fix typo in pattern usefulness documentation Line 171 introduced and as variable names, but line 172 incorrectly used . This commit fixes the inconsistency to use the correct variable names throughout. Fixes #149803
2 parents 24ba7d8 + 65c1070 commit c0c4525

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

compiler/rustc_pattern_analysis/src/usefulness.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@
169169
//! on pattern-tuples.
170170
//!
171171
//! Let `pt_1, .., pt_n` and `qt` be length-m tuples of patterns for the same type `(T_1, .., T_m)`.
172-
//! We compute `usefulness(tp_1, .., tp_n, tq)` as follows:
172+
//! We compute `usefulness(pt_1, .., pt_n, qt)` as follows:
173173
//!
174174
//! - Base case: `m == 0`.
175175
//! The pattern-tuples are all empty, i.e. they're all `()`. Thus `tq` is useful iff there are

0 commit comments

Comments
 (0)