diff options
| author | Mustafa Quraish <[email protected]> | 2022-02-01 04:08:59 -0500 |
|---|---|---|
| committer | Mustafa Quraish <[email protected]> | 2022-02-01 04:08:59 -0500 |
| commit | d471a41369690a9d2d9b8862ea5ff0ae9cbe40fc (patch) | |
| tree | 9399d12700c3d975a95b0946833dc419b3268419 /src/ast.h | |
| parent | Testing: Add support for testing stdout results, check builtins (diff) | |
| download | cup-d471a41369690a9d2d9b8862ea5ff0ae9cbe40fc.tar.xz cup-d471a41369690a9d2d9b8862ea5ff0ae9cbe40fc.zip | |
Add basic `defer` implementation.
We don't have any closures yet, so it's essentially the same as just
moving the statement after the `defer` keyword to the end of the block/
right before returning from the function.
Diffstat (limited to 'src/ast.h')
| -rw-r--r-- | src/ast.h | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -28,6 +28,7 @@ F(AST_CONDITIONAL, "conditional expression") \ F(AST_IF, "if statement") \ F(AST_WHILE, "while statement") \ + F(AST_DEFER, "defer statement") \ F(AST_FOR, "for statement") \ F(AST_VARDECL, "variable decl") \ F(AST_LOCAL_VAR, "local variable") \ |