mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 06:07:34 +00:00
LibJS: Make SuperCall a proper AST node and clean up evaluation
This commit is contained in:
parent
d81f4d5228
commit
71fc7ac7ac
3 changed files with 74 additions and 22 deletions
|
@ -951,6 +951,21 @@ public:
|
|||
virtual bool is_new_expression() const override { return true; }
|
||||
};
|
||||
|
||||
class SuperCall final : public Expression {
|
||||
public:
|
||||
SuperCall(SourceRange source_range, Vector<CallExpression::Argument> arguments)
|
||||
: Expression(source_range)
|
||||
, m_arguments(move(arguments))
|
||||
{
|
||||
}
|
||||
|
||||
virtual Value execute(Interpreter&, GlobalObject&) const override;
|
||||
virtual void dump(int indent) const override;
|
||||
|
||||
private:
|
||||
Vector<CallExpression::Argument> const m_arguments;
|
||||
};
|
||||
|
||||
enum class AssignmentOp {
|
||||
Assignment,
|
||||
AdditionAssignment,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue