| 1 | package Zuzu::AST::Expr::Array; | ||
| 2 | |||
| 3 | 78 | ▶ | use utf8; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | |||
| 5 | 78 | our $VERSION = '0.007002'; | |
| 6 | |||
| 7 | 78 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 8 | |||
| 9 | 78 | has 'items' => ( is => 'rw' ); | |
| 10 | |||
| 11 | 78 | with 'Zuzu::AST::Role::Node'; | |
| 12 | |||
| 13 | 2850 | ▶ | sub evaluate { $_[1]->eval_array($_[0]) } |
|
Subroutine
evaluate: called CC=1 SCAR=0.0
Pod
documented
| |||
| 14 | |||
| 15 | =pod | ||
| 16 | |||
| 17 | =head1 NAME | ||
| 18 | |||
| 19 | Zuzu::AST::Expr::Array - AST node for array expressions | ||
| 20 | |||
| 21 | =head1 DESCRIPTION | ||
| 22 | |||
| 23 | Represents one expression form in the abstract syntax tree and delegates evaluation to C<Zuzu::Runtime>. | ||
| 24 | |||
| 25 | =head1 INHERITANCE | ||
| 26 | |||
| 27 | Inherits from C<Moo::Object>. | ||
| 28 | |||
| 29 | =head1 ROLES | ||
| 30 | |||
| 31 | Consumes C<Zuzu::AST::Role::Node>. | ||
| 32 | |||
| 33 | =head1 ATTRIBUTES | ||
| 34 | |||
| 35 | =head2 items | ||
| 36 | |||
| 37 | Type: B<ArrayRef>. | ||
| 38 | |||
| 39 | Ordered array elements (expressions or runtime values). | ||
| 40 | |||
| 41 | =head1 METHODS | ||
| 42 | |||
| 43 | =head2 evaluate | ||
| 44 | |||
| 45 | Dispatches this AST node to the matching runtime evaluator. | ||
| 46 | |||
| 47 | =head1 SEE ALSO | ||
| 48 | |||
| 49 | C<Zuzu::AST::Role::Node>. | ||
| 50 | |||
| 51 | Subclasses: none in this distribution. | ||
| 52 | |||
| 53 | =head1 COPYRIGHT AND LICENCE | ||
| 54 | |||
| 55 | B<< Zuzu::AST::Expr::Array >> is copyright Toby Inkster. | ||
| 56 | |||
| 57 | It is free software; you may redistribute it and/or modify it under | ||
| 58 | the terms of either the Artistic License 1.0 or the GNU General Public | ||
| 59 | License version 2. | ||
| 60 | |||
| 61 | =cut | ||
| 62 | |||
| 63 | 78 | 1; | |