diff --git a/Cargo.lock b/Cargo.lock index c90ea73..5ea5225 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1657,6 +1657,7 @@ dependencies = [ "simplelog", "sqlx", "thiserror", + "tinyvec", "tokio", "tokio-util", "toml 0.8.19", diff --git a/Cargo.toml b/Cargo.toml index 6341740..14d5eed 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -37,6 +37,7 @@ serde = { version = "1.0.147", features = ["derive"] } serde_derive = "1.0.147" serde_json = "1.0.122" simplelog = "0.12.2" +tinyvec = "1.8.0" thiserror = "1.0.62" tokio = { version = "1.39", features = ["macros", "rt-multi-thread"] } tokio-util = { version = "0.7.11", features = ["io"] } diff --git a/src/app/index/browser.rs b/src/app/index/browser.rs index d609422..0d705c3 100644 --- a/src/app/index/browser.rs +++ b/src/app/index/browser.rs @@ -7,6 +7,7 @@ use std::{ use lasso2::ThreadedRodeo; use serde::{Deserialize, Serialize}; +use tinyvec::TinyVec; use trie_rs::{Trie, TrieBuilder}; use crate::app::index::{InternPath, PathID}; @@ -139,7 +140,7 @@ impl Builder { song.virtual_path .components() .map(|c| strings.get_or_intern(c.as_os_str().to_str().unwrap())) - .collect::>(), + .collect::>(), ); }