diff options
Diffstat (limited to 'src/zilch/Env')
| -rw-r--r-- | src/zilch/Env/Function.zig | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/zilch/Env/Function.zig b/src/zilch/Env/Function.zig index 692ce2b..c37b1c7 100644 --- a/src/zilch/Env/Function.zig +++ b/src/zilch/Env/Function.zig @@ -4,10 +4,12 @@ const Self = @This(); content: []const u8, id: u32, +await: bool, pub fn from(content: []const u8) Self { return .{ .content = content, .id = std.hash.XxHash32.hash(4654, content), + .await = std.mem.startsWith(u8, content, "async ") or std.mem.startsWith(u8, content, "async("), }; } |