Product Site

5.4.27.4. value (Attribute)

value get:

Returns the current value of the referenced variable.
value set:

Sets the value of the referenced variable to object.

See also method name.

Example 5.323. VariableReference class — value method
array = 1, 2, 3

say >array~class~id                  -- VariableReference
say >array~value~class~id            -- Array

say >array~value~toString(, ", ")    -- 1, 2, 3
-- this also works because we have an UNKNOWN method
say >array~toString(, ", ")          -- 1, 2, 3