blob: e40f8f06f50973a66bbe9eaeffb58626012f825e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
/**
** \file ast/cast-exp.cc
** \brief Implementation of ast::CastExp.
*/
#include <ast/cast-exp.hh>
#include <ast/visitor.hh>
namespace ast
{
CastExp::CastExp(const Location& location, Exp* exp, Ty* ty)
: Exp(location)
, exp_(exp)
, ty_(ty)
{}
CastExp::~CastExp()
{
delete exp_;
delete ty_;
}
void CastExp::accept(ConstVisitor& v) const { v(*this); }
void CastExp::accept(Visitor& v) { v(*this); }
} // namespace ast
|