Skip to content

Commit 0da2f33

Browse files
committed
[Pair] elaborate on literals; add X<> anchors
1 parent c61ad58 commit 0da2f33

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lib/Pair.pod

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,18 @@ Consists of two parts, a I<key> and a I<value>. C<Pair>s can be seen as the
88
atomic units in C<Hash>es, and they are also used in conjunction with named
99
arguments and parameters.
1010
11+
X<:> X<< => >> X<:!>
1112
There are three syntaxes for C<Pair>s:
1213
1314
'key' => 'value' # this...
1415
:key<value> # ...means the same as this
1516
:$foo # short for foo => $foo
1617
18+
Variants of this are
19+
20+
:key # same as key => True
21+
:!key # same as key => False
22+
1723
The immutable version of a C<Pair> is an C<Enum>.
1824
1925
=head1 Methods

0 commit comments

Comments
 (0)