NAME

Zuzu::AST::Expr::New - AST node for object construction expressions

DESCRIPTION

Represents a new ClassName(...) expression with named constructor arguments.

INHERITANCE

Inherits from Moo::Object.

ROLES

Consumes Zuzu::AST::Role::Node.

ATTRIBUTES

class_expr

Type: Zuzu::AST::Role::Node.

Expression that resolves to the class value being instantiated.

traits

Type: ArrayRef[Zuzu::AST::Role::Node].

Optional trait references to compose for this one constructed object.

args

Type: ArrayRef[ArrayRef].

Ordered constructor named arguments as [ key, expr ] pairs.

METHODS

evaluate

Dispatches this AST node to the matching runtime evaluator.

SEE ALSO

Zuzu::AST::Role::Node.

Subclasses: none in this distribution.

COPYRIGHT AND LICENCE

Zuzu::AST::Expr::New is copyright Toby Inkster.

It is free software; you may redistribute it and/or modify it under the terms of either the Artistic License 1.0 or the GNU General Public License version 2.