syntax VAR

Documentation for syntax VAR assembled from the following types:

language documentation Meta-object protocol

From Meta-object protocol

(Meta-object protocol) syntax VAR

Returns the underlying Scalar object, if there is one.

The presence of a Scalar object indicates that the object is "itemized".

.say for (123);           # OUTPUT: «1␤2␤3␤», not itemized 
.say for $(123);          # OUTPUT: «(1 2 3)␤», itemized 
say (123).VAR ~~ Scalar;  # OUTPUT: «False␤» 
say $(123).VAR ~~ Scalar# OUTPUT: «True␤»