Skip unecessary allocations

This commit is contained in:
Antoine Gersant 2024-08-09 08:40:44 -07:00
parent 169b2b5cb8
commit 0a1f3fa78d

View file

@ -87,7 +87,7 @@ impl Browser {
.map(|c: Vec<_>| -> PathBuf { .map(|c: Vec<_>| -> PathBuf {
c.into_iter() c.into_iter()
.map(|s| strings.resolve(&s)) .map(|s| strings.resolve(&s))
.collect::<Vec<_>>() .collect::<TinyVec<[&str; 8]>>()
.join(std::path::MAIN_SEPARATOR_STR) .join(std::path::MAIN_SEPARATOR_STR)
.into() .into()
}) })