mirror of
https://github.com/rust-lang/rust-clippy
synced 2025-02-17 06:28:42 +00:00
Rename the unescaping functions.
`unescape_literal` becomes `unescape_unicode`, and `unescape_c_string` becomes `unescape_mixed`. Because rfc3349 will mean that C string literals will no longer be the only mixed utf8 literals.
This commit is contained in:
parent
6b359b7e1b
commit
9cbc5829a8
1 changed files with 1 additions and 1 deletions
|
@ -928,7 +928,7 @@ fn remove_line_splices(s: &str) -> String {
|
||||||
.and_then(|s| s.strip_suffix('"'))
|
.and_then(|s| s.strip_suffix('"'))
|
||||||
.unwrap_or_else(|| panic!("expected quoted string, found `{s}`"));
|
.unwrap_or_else(|| panic!("expected quoted string, found `{s}`"));
|
||||||
let mut res = String::with_capacity(s.len());
|
let mut res = String::with_capacity(s.len());
|
||||||
unescape::unescape_literal(s, unescape::Mode::Str, &mut |range, ch| {
|
unescape::unescape_unicode(s, unescape::Mode::Str, &mut |range, ch| {
|
||||||
if ch.is_ok() {
|
if ch.is_ok() {
|
||||||
res.push_str(&s[range]);
|
res.push_str(&s[range]);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue