Use ImmutableString in more places.

This commit is contained in:
Stephen Chung
2022-10-29 14:59:20 +08:00
parent 8e35f98477
commit 91415b9750
11 changed files with 45 additions and 85 deletions

View File

@@ -619,7 +619,7 @@ impl Expr {
if !x.is_qualified() && x.args.len() == 1 && x.name == KEYWORD_FN_PTR =>
{
if let Self::StringConstant(ref s, ..) = x.args[0] {
FnPtr::new(s).ok()?.into()
FnPtr::new(s.clone()).ok()?.into()
} else {
return None;
}