diff options
| author | Andy Russell <arussell123@gmail.com> | 2019-03-05 11:50:33 -0500 |
|---|---|---|
| committer | Andy Russell <arussell123@gmail.com> | 2019-03-05 18:45:08 -0500 |
| commit | fe96ffeac98481433c33e3e9f49a56f70f8ec134 (patch) | |
| tree | d8a1beb253175c96b4c4a7d38ae1603731546142 /clippy_lints/src/large_enum_variant.rs | |
| parent | a8f61e70a8c1c438658d0c30080fc3ce3be6c2df (diff) | |
| download | rust-fe96ffeac98481433c33e3e9f49a56f70f8ec134.tar.gz rust-fe96ffeac98481433c33e3e9f49a56f70f8ec134.zip | |
move lint documentation into macro invocations
Diffstat (limited to 'clippy_lints/src/large_enum_variant.rs')
| -rw-r--r-- | clippy_lints/src/large_enum_variant.rs | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/clippy_lints/src/large_enum_variant.rs b/clippy_lints/src/large_enum_variant.rs index 7a1a0e599c1..2e38fcf0367 100644 --- a/clippy_lints/src/large_enum_variant.rs +++ b/clippy_lints/src/large_enum_variant.rs @@ -7,23 +7,23 @@ use rustc::ty::layout::LayoutOf; use rustc::{declare_tool_lint, lint_array}; use rustc_errors::Applicability; -/// **What it does:** Checks for large size differences between variants on -/// `enum`s. -/// -/// **Why is this bad?** Enum size is bounded by the largest variant. Having a -/// large variant -/// can penalize the memory layout of that enum. -/// -/// **Known problems:** None. -/// -/// **Example:** -/// ```rust -/// enum Test { -/// A(i32), -/// B([i32; 8000]), -/// } -/// ``` declare_clippy_lint! { + /// **What it does:** Checks for large size differences between variants on + /// `enum`s. + /// + /// **Why is this bad?** Enum size is bounded by the largest variant. Having a + /// large variant + /// can penalize the memory layout of that enum. + /// + /// **Known problems:** None. + /// + /// **Example:** + /// ```rust + /// enum Test { + /// A(i32), + /// B([i32; 8000]), + /// } + /// ``` pub LARGE_ENUM_VARIANT, perf, "large size difference between variants on an enum" |
