aboutsummaryrefslogtreecommitdiff
path: root/include/cps
diff options
context:
space:
mode:
Diffstat (limited to 'include/cps')
-rw-r--r--include/cps/AST.h7
-rw-r--r--include/cps/Lexer.h2
2 files changed, 8 insertions, 1 deletions
diff --git a/include/cps/AST.h b/include/cps/AST.h
index c2754a5..f20b106 100644
--- a/include/cps/AST.h
+++ b/include/cps/AST.h
@@ -174,6 +174,13 @@ public:
ExprAST *getExpr() const { return Expr.get(); }
};
+class DeleteStmtAST : public StmtAST {
+ std::unique_ptr<ExprAST> Target;
+public:
+ explicit DeleteStmtAST(std::unique_ptr<ExprAST> T) : Target(std::move(T)) {}
+ ExprAST *getTarget() const { return Target.get(); }
+};
+
class InputStmtAST : public StmtAST {
std::unique_ptr<ExprAST> Target;
public:
diff --git a/include/cps/Lexer.h b/include/cps/Lexer.h
index 716dc4a..b465591 100644
--- a/include/cps/Lexer.h
+++ b/include/cps/Lexer.h
@@ -99,7 +99,7 @@ enum Token {
tok_c_char = -610,
tok_c_string = -611,
tok_c_double = -612,
- tok_new = -613,
+ tok_new = -613, tok_delete = -614,
tok_try = -700,
tok_catch = -701,