mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-27 18:57:42 +03:00
Fix typo in pattern usefulness documentation
Line 171 introduced `pt_1, .., pt_n` and `qt` as variable names, but line 172 incorrectly used `tp_1, .., tp_n, tq`. This commit fixes the inconsistency to use the correct variable names throughout.
This commit is contained in:
@@ -169,7 +169,7 @@
|
||||
//! on pattern-tuples.
|
||||
//!
|
||||
//! Let `pt_1, .., pt_n` and `qt` be length-m tuples of patterns for the same type `(T_1, .., T_m)`.
|
||||
//! We compute `usefulness(tp_1, .., tp_n, tq)` as follows:
|
||||
//! We compute `usefulness(pt_1, .., pt_n, qt)` as follows:
|
||||
//!
|
||||
//! - Base case: `m == 0`.
|
||||
//! The pattern-tuples are all empty, i.e. they're all `()`. Thus `tq` is useful iff there are
|
||||
|
||||
Reference in New Issue
Block a user