Skip to content

Commit

Permalink
Convert unused_tuple_struct_fields to warn-by-default
Browse files Browse the repository at this point in the history
  • Loading branch information
shepmaster committed Nov 25, 2023
1 parent 7e2c7e4 commit d254a5f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions compiler/rustc_lint_defs/src/builtin.rs
Expand Up @@ -611,7 +611,6 @@ declare_lint! {
/// ### Example
///
/// ```rust
/// #[warn(unused_tuple_struct_fields)]
/// struct S(i32, i32, i32);
/// let s = S(1, 2, 3);
/// let _ = (s.0, s.2);
Expand All @@ -626,7 +625,7 @@ declare_lint! {
/// removing the unused field(s) or, to preserve the numbering of the
/// remaining fields, change the unused field(s) to have unit type.
pub UNUSED_TUPLE_STRUCT_FIELDS,
Allow,
Warn,
"detects tuple struct fields that are never read"
}

Expand Down

0 comments on commit d254a5f

Please sign in to comment.