aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_assists
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-05-14 00:10:05 +0100
committerGitHub <[email protected]>2020-05-14 00:10:05 +0100
commit62730ae30db453f53eb0c37647b5c76058eafca0 (patch)
tree71caf8f1abdea2bd1de8be38e4595b7dac38ae85 /crates/ra_assists
parent530a35f3f949d70c53accede35fa561429585bc1 (diff)
parent2d0a9492362e47c51f389d586a43c81328be4670 (diff)
Merge #4452
4452: Use back ticks instead of single quotes around code r=matklad a=tspiteri Also, use back ticks instead of single quotes in `rustc_unescape_error_to_string` for `EE:UnclosedUnicodeEscape`. Co-authored-by: Trevor Spiteri <[email protected]>
Diffstat (limited to 'crates/ra_assists')
-rw-r--r--crates/ra_assists/src/handlers/add_custom_impl.rs2
-rw-r--r--crates/ra_assists/src/handlers/add_explicit_type.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_assists/src/handlers/add_custom_impl.rs b/crates/ra_assists/src/handlers/add_custom_impl.rs
index 795a225a4..2baeb8607 100644
--- a/crates/ra_assists/src/handlers/add_custom_impl.rs
+++ b/crates/ra_assists/src/handlers/add_custom_impl.rs
@@ -49,7 +49,7 @@ pub(crate) fn add_custom_impl(acc: &mut Assists, ctx: &AssistContext) -> Option<
49 let start_offset = annotated.syntax().parent()?.text_range().end(); 49 let start_offset = annotated.syntax().parent()?.text_range().end();
50 50
51 let label = 51 let label =
52 format!("Add custom impl '{}' for '{}'", trait_token.text().as_str(), annotated_name); 52 format!("Add custom impl `{}` for `{}`", trait_token.text().as_str(), annotated_name);
53 53
54 let target = attr.syntax().text_range(); 54 let target = attr.syntax().text_range();
55 acc.add(AssistId("add_custom_impl"), label, target, |edit| { 55 acc.add(AssistId("add_custom_impl"), label, target, |edit| {
diff --git a/crates/ra_assists/src/handlers/add_explicit_type.rs b/crates/ra_assists/src/handlers/add_explicit_type.rs
index 7ced00626..0c7d5e355 100644
--- a/crates/ra_assists/src/handlers/add_explicit_type.rs
+++ b/crates/ra_assists/src/handlers/add_explicit_type.rs
@@ -61,7 +61,7 @@ pub(crate) fn add_explicit_type(acc: &mut Assists, ctx: &AssistContext) -> Optio
61 let inferred_type = ty.display_source_code(ctx.db, module.into()).ok()?; 61 let inferred_type = ty.display_source_code(ctx.db, module.into()).ok()?;
62 acc.add( 62 acc.add(
63 AssistId("add_explicit_type"), 63 AssistId("add_explicit_type"),
64 format!("Insert explicit type '{}'", inferred_type), 64 format!("Insert explicit type `{}`", inferred_type),
65 pat_range, 65 pat_range,
66 |builder| match ascribed_ty { 66 |builder| match ascribed_ty {
67 Some(ascribed_ty) => { 67 Some(ascribed_ty) => {