diff options
Diffstat (limited to 'tiger-compiler/src/ast/call-exp.cc')
| -rw-r--r-- | tiger-compiler/src/ast/call-exp.cc | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/tiger-compiler/src/ast/call-exp.cc b/tiger-compiler/src/ast/call-exp.cc new file mode 100644 index 0000000..546ab5f --- /dev/null +++ b/tiger-compiler/src/ast/call-exp.cc @@ -0,0 +1,27 @@ +/** + ** \file ast/call-exp.cc + ** \brief Implementation of ast::CallExp. + */ + +#include <ast/call-exp.hh> +#include <ast/visitor.hh> +#include <misc/algorithm.hh> + +namespace ast +{ + CallExp::CallExp(const Location& location, misc::symbol name, exps_type* args) + : Exp(location) + , name_(name) + , args_(args) + {} + + CallExp::~CallExp() + { + misc::deep_clear(*args_); + delete args_; + } + + void CallExp::accept(ConstVisitor& v) const { v(*this); } + + void CallExp::accept(Visitor& v) { v(*this); } +} // namespace ast |
