Skip to content

Commit d0b5663

Browse files
committed
Fix usage of backquotes in suggestion
1 parent c86a7e5 commit d0b5663

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

clippy_lints/src/utils/internal_lints.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -704,7 +704,7 @@ impl<'tcx> LateLintPass<'tcx> for MatchTypeOnDiagItem {
704704
cx,
705705
MATCH_TYPE_ON_DIAGNOSTIC_ITEM,
706706
expr.span,
707-
"usage of `utils::match_type() on a type diagnostic item`",
707+
"usage of `utils::match_type()` on a type diagnostic item",
708708
"try",
709709
format!("utils::is_type_diagnostic_item({}, {}, sym!({}))", cx_snippet, ty_snippet, item_name),
710710
Applicability::MaybeIncorrect,

tests/ui/match_type_on_diag_item.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
error: usage of `utils::match_type() on a type diagnostic item`
1+
error: usage of `utils::match_type()` on a type diagnostic item
22
--> $DIR/match_type_on_diag_item.rs:41:17
33
|
44
LL | let _ = match_type(cx, ty, &paths::VEC);
@@ -11,19 +11,19 @@ LL | #![deny(clippy::internal)]
1111
| ^^^^^^^^^^^^^^^^
1212
= note: `#[deny(clippy::match_type_on_diagnostic_item)]` implied by `#[deny(clippy::internal)]`
1313

14-
error: usage of `utils::match_type() on a type diagnostic item`
14+
error: usage of `utils::match_type()` on a type diagnostic item
1515
--> $DIR/match_type_on_diag_item.rs:42:17
1616
|
1717
LL | let _ = match_type(cx, ty, &OPTION);
1818
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `utils::is_type_diagnostic_item(cx, ty, sym!(option_type))`
1919

20-
error: usage of `utils::match_type() on a type diagnostic item`
20+
error: usage of `utils::match_type()` on a type diagnostic item
2121
--> $DIR/match_type_on_diag_item.rs:43:17
2222
|
2323
LL | let _ = match_type(cx, ty, &["core", "result", "Result"]);
2424
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `utils::is_type_diagnostic_item(cx, ty, sym!(result_type))`
2525

26-
error: usage of `utils::match_type() on a type diagnostic item`
26+
error: usage of `utils::match_type()` on a type diagnostic item
2727
--> $DIR/match_type_on_diag_item.rs:46:17
2828
|
2929
LL | let _ = utils::match_type(cx, ty, rc_path);

0 commit comments

Comments
 (0)