Upgrade hash table

Former-commit-id: 5d208f9ea0
This commit is contained in:
Jarred Sumner
2021-06-06 21:16:43 -07:00
parent 13653a93a2
commit 079fe523d4
9 changed files with 126 additions and 66 deletions

View File

@@ -97,6 +97,10 @@ pub fn endsWithAnyComptime(self: string, comptime str: string) bool {
pub fn eql(self: string, other: anytype) bool {
if (self.len != other.len) return false;
if (comptime @TypeOf(other) == *string) {
return eql(self, other.*);
}
for (self) |c, i| {
if (other[i] != c) return false;
}