4 ms·
my %ordered-hash is OrderedHash; my @ordered-hash := %ordered-hash; If you don't care for sigils: my \ordered-hash = OrderedHash.new; say ordered
by b2gills 9y ago
my %ordered-hash is OrderedHash;
my @ordered-hash := %ordered-hash;
If you don't care for sigils:
my \ordered-hash = OrderedHash.new;
say ordered-hash<foo>;
for ordered-hash {…}
Note that you can only assign to sigilless variables when you declare them.
You could assign an anonymous scalar to it to allow you to assign to it later.
my \sigilless = my Int:D $ is default(0) = 5;
sigilless = 4;