diff options
| author | Nathaniel Hamovitz <18648574+nhamovitz@users.noreply.github.com> | 2021-10-18 03:52:57 -0700 |
|---|---|---|
| committer | Nathaniel Hamovitz <18648574+nhamovitz@users.noreply.github.com> | 2021-10-18 03:52:57 -0700 |
| commit | a54dbf6445f923b6b315a4c9b08f3e45eaac0081 (patch) | |
| tree | e3e5d806ae2bbb9473d637a0ae385a1b1a9d5154 | |
| parent | a6aa9864a339783e2e8400053408a197b607301d (diff) | |
| download | rust-a54dbf6445f923b6b315a4c9b08f3e45eaac0081.tar.gz rust-a54dbf6445f923b6b315a4c9b08f3e45eaac0081.zip | |
Improve doc and span messages
| -rw-r--r-- | clippy_lints/src/trailing_zero_sized_array_without_repr.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clippy_lints/src/trailing_zero_sized_array_without_repr.rs b/clippy_lints/src/trailing_zero_sized_array_without_repr.rs index 0267f7bdf0e..98f5073681d 100644 --- a/clippy_lints/src/trailing_zero_sized_array_without_repr.rs +++ b/clippy_lints/src/trailing_zero_sized_array_without_repr.rs @@ -31,7 +31,7 @@ declare_clippy_lint! { /// ``` pub TRAILING_ZERO_SIZED_ARRAY_WITHOUT_REPR, nursery, - "struct with a trailing zero-sized array but without `repr(C)` or another `repr` attribute" + "struct with a trailing zero-sized array but without `#[repr(C)]` or another `repr` attribute" } declare_lint_pass!(TrailingZeroSizedArrayWithoutRepr => [TRAILING_ZERO_SIZED_ARRAY_WITHOUT_REPR]); @@ -54,9 +54,9 @@ impl<'tcx> LateLintPass<'tcx> for TrailingZeroSizedArrayWithoutRepr { cx, TRAILING_ZERO_SIZED_ARRAY_WITHOUT_REPR, lint_span, - "trailing zero-sized array in a struct which is not marked `#[repr(C)]`", + "trailing zero-sized array in a struct which is not marked with a `repr` attribute", None, - "consider annotating the struct definition with `#[repr(C)]` (or another `repr` attribute)", + "consider annotating the struct definition with `#[repr(C)]` or another `repr` attribute", ); } } |
