diff options
author | Aleksey Kladov <[email protected]> | 2020-11-06 21:21:56 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2020-11-06 21:23:14 +0000 |
commit | 5ba4f949c23dcf53f34995c90b7c01e6c641b1f0 (patch) | |
tree | fe5064dde4e948a776c87d38fba972903acad3ec /crates/assists/src/handlers/replace_string_with_char.rs | |
parent | 6725dcf847300b9cddcbb061b159317113860f31 (diff) |
Kill RAW_ literals
Syntactically, they are indistinguishable from non-raw versions, so it
doesn't make sense to separate then *at the syntax* level.
Diffstat (limited to 'crates/assists/src/handlers/replace_string_with_char.rs')
-rw-r--r-- | crates/assists/src/handlers/replace_string_with_char.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/assists/src/handlers/replace_string_with_char.rs b/crates/assists/src/handlers/replace_string_with_char.rs index 4ca87a8ec..6d227e883 100644 --- a/crates/assists/src/handlers/replace_string_with_char.rs +++ b/crates/assists/src/handlers/replace_string_with_char.rs | |||
@@ -22,7 +22,7 @@ use crate::{AssistContext, AssistId, AssistKind, Assists}; | |||
22 | // } | 22 | // } |
23 | // ``` | 23 | // ``` |
24 | pub(crate) fn replace_string_with_char(acc: &mut Assists, ctx: &AssistContext) -> Option<()> { | 24 | pub(crate) fn replace_string_with_char(acc: &mut Assists, ctx: &AssistContext) -> Option<()> { |
25 | let token = ctx.find_token_at_offset(STRING).and_then(ast::String::cast)?; | 25 | let token = ctx.find_token_syntax_at_offset(STRING).and_then(ast::String::cast)?; |
26 | let value = token.value()?; | 26 | let value = token.value()?; |
27 | let target = token.syntax().text_range(); | 27 | let target = token.syntax().text_range(); |
28 | 28 | ||