Replace more Name::to_string usages with Name::to_smol_str

This commit is contained in:
Lukas Wirth 2021-11-04 18:12:05 +01:00
parent 962be38004
commit 439a8194b0
24 changed files with 49 additions and 41 deletions

View file

@ -113,7 +113,7 @@ pub fn mod_path_to_ast(path: &hir::ModPath) -> ast::Path {
segments.extend(
path.segments()
.iter()
.map(|segment| make::path_segment(make::name_ref(&segment.to_string()))),
.map(|segment| make::path_segment(make::name_ref(&segment.to_smol_str()))),
);
make::path_from_segments(segments, is_abs)
}