Update Wasmer, log load times, some minor performance tweaks
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
@@ -129,10 +129,13 @@ impl ValueIdentifiable for StringKey {
|
||||
}
|
||||
}
|
||||
|
||||
/// The difference in ascii characters to translate from uppercase to lowercase.
|
||||
const CAPITAL_DIFF: u8 = b'a' - b'A';
|
||||
|
||||
/// Converts a character to lowercased in a const safe way.
|
||||
const fn to_lower(c: u8) -> u8 {
|
||||
if c >= b'A' && c <= b'Z' {
|
||||
return c + (b'a' - b'A');
|
||||
return c + CAPITAL_DIFF;
|
||||
}
|
||||
c
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user