chore: fix formatting

This commit is contained in:
Rekai Nyangadzayi Musuka 2023-04-10 23:57:10 -05:00
parent 5e630120f2
commit 4a983bd1e6
1 changed files with 212 additions and 210 deletions

View File

@ -175,7 +175,9 @@ fn walk(node: *const Node, indent: u8) void {
fn hash(key: []const u8) u32 { fn hash(key: []const u8) u32 {
var result: u32 = 0; var result: u32 = 0;
for (key) |c| result |= @as(u32, 1) << @intCast(u5, c - 'a');
// 6 because we're working with 'a' -> 'z'
for (key) |c| result |= @as(u32, 1) << 6 + @intCast(u5, c - 'a');
return result; return result;
} }