diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2022-10-03 08:00:47 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-10-03 08:00:47 +0200 |
| commit | d679ec5e2fbcccd8d680ecda47a232b87ba00161 (patch) | |
| tree | da937ed323fdf428464ec09512efbb1a9cc785a8 /compiler | |
| parent | c3053309c51b01bc51944f044a61f43de86d9fd8 (diff) | |
| parent | afae9576dcff73e0b674286be3636d9a101a60f7 (diff) | |
| download | rust-d679ec5e2fbcccd8d680ecda47a232b87ba00161.tar.gz rust-d679ec5e2fbcccd8d680ecda47a232b87ba00161.zip | |
Rollup merge of #102591 - JarvisCraft:fix-double-a-article, r=compiler-errors
Fix duplicate usage of `a` article. This fixes a typo first appearing in #94624 in which test-macro diagnostic uses "a" article twice. Since I searched the sources for " a a " sequences, I also fixed the same issue in a few files where I found it.
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/rustc_builtin_macros/src/test.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_builtin_macros/src/test.rs b/compiler/rustc_builtin_macros/src/test.rs index 7efb6cc61ee..705141614e2 100644 --- a/compiler/rustc_builtin_macros/src/test.rs +++ b/compiler/rustc_builtin_macros/src/test.rs @@ -115,7 +115,7 @@ pub fn expand_test_or_bench( // reworked in the future to not need it, it'd be nice. _ => diag.struct_span_err(attr_sp, msg).forget_guarantee(), }; - err.span_label(attr_sp, "the `#[test]` macro causes a a function to be run on a test and has no effect on non-functions") + err.span_label(attr_sp, "the `#[test]` macro causes a function to be run on a test and has no effect on non-functions") .span_label(item.span, format!("expected a non-associated function, found {} {}", item.kind.article(), item.kind.descr())) .span_suggestion(attr_sp, "replace with conditional compilation to make the item only exist when tests are being run", "#[cfg(test)]", Applicability::MaybeIncorrect) .emit(); |
