perf: drop ini-core crate for simpler parser using memchr and bstr

This commit is contained in:
Michael Aaron Murphy 2025-12-01 15:19:01 +01:00
parent 44edef9673
commit 8b045f90c7
No known key found for this signature in database
GPG key ID: B2732D4240C9212C
6 changed files with 413 additions and 94 deletions

View file

@ -72,9 +72,9 @@ impl Default for DirectoryType {
}
}
impl From<&str> for DirectoryType {
fn from(value: &str) -> Self {
match value.as_bytes()[0] {
impl From<&[u8]> for DirectoryType {
fn from(value: &[u8]) -> Self {
match value[0] {
b'F' => DirectoryType::Fixed,
b'S' => DirectoryType::Scalable,
_ => DirectoryType::Threshold,