Ruby 4.1.0dev (2026-11-17 revision 373d8c72a360f0d6c3be9cd13d1f0c27360e5d90)
pm_array_elements_t Struct Reference

The elements of an ArrayNode node that is still being parsed. More...

Data Fields

pm_node_list_t nodes
 The open list of elements.
bool dynamic
 Whether any element keeps the array from being a static literal.
bool contains_splat
 Whether any element is a splat.

Detailed Description

The elements of an ArrayNode node that is still being parsed.

Its flags are worked out as each element is appended, while the element is still in cache, and they are kept so that a zeroed value is an empty array.

Definition at line 2482 of file prism.c.

Field Documentation

◆ contains_splat

bool pm_array_elements_t::contains_splat

Whether any element is a splat.

Definition at line 2493 of file prism.c.

◆ dynamic

bool pm_array_elements_t::dynamic

Whether any element keeps the array from being a static literal.

Nested arrays, hashes, and ranges never count as static literals here.

Definition at line 2490 of file prism.c.

◆ nodes

pm_node_list_t pm_array_elements_t::nodes

The open list of elements.

Definition at line 2484 of file prism.c.


The documentation for this struct was generated from the following file: