perf: drop ini-core crate for simpler parser using memchr and bstr
This commit is contained in:
parent
44edef9673
commit
8b045f90c7
6 changed files with 413 additions and 94 deletions
|
|
@ -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,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue