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t::Formatter) -> std::fmt::Result {
write!(fmt, "\"")?;
for c in self.0.chars() {
if c == '"' {
write!(fmt, "\\{}", c)?
} else if c == '\\' {
write!(fmt, "\\\\")?
} else {
write!(fmt, "{}", c)?
}
}
write!(fmt, "\"")?;
Ok(())
}
}
fn unescape(s: &str) -> std::borrow::Cow<str> {
let mut b = 0;
let mut result = String::new();
let mut ch = s.chars();
while let Some(c) = ch.next() {
if c == '\\' {
if result.is_empty() {
result = s.split_at(b).0.to_string();
}
if let Some(c) = ch.next() {
result.push(c)
}
} else if !result.is_empty() {
result.push(c)
}
b += c.len_utf8()
}
if result.is_empty() {
s.into()
} else {
result.into()
}
}