mirror of
https://github.com/odin-lang/Odin.git
synced 2026-04-19 06:49:55 -04:00
Split keys and slots and allocate them both together
This commit is contained in:
@@ -182,8 +182,9 @@ gb_internal isize string_index_byte(String const &s, u8 x) {
|
||||
}
|
||||
|
||||
gb_internal gb_inline bool str_eq(String const &a, String const &b) {
|
||||
if (a.len != b.len) return false;
|
||||
if (a.len == 0) return true;
|
||||
if (a.len != b.len) return false;
|
||||
if (a.len == 0) return true;
|
||||
if (a.text == b.text) return true;
|
||||
return memcmp(a.text, b.text, a.len) == 0;
|
||||
}
|
||||
gb_internal gb_inline bool str_ne(String const &a, String const &b) { return !str_eq(a, b); }
|
||||
|
||||
Reference in New Issue
Block a user