7
7
* [Constants](#constants)
8
8
* [Scope](#variable-scope): [Declarator](#variable-scope-decalarator)
9
9
* [Type](#variable-type): [Undefined](#variable-type-undefined), [Immutable](#variable-type-immutable), [Mutable](#variable-type-mutable), [Low Level](#variable-type-low-level), [Introspection](#variable-type-introspection)
10
- * Operators
11
- * Precedence
12
- * Associativity
13
- * Categories: Main, Regex
14
- * Meta
15
- * Unicode
16
- * Contextualizers
17
- * Junctions
18
- * Sets
19
- * Smartmatch
20
- * Files Tests
21
- * Quoting
22
- * Text
23
- * Regex
10
+ * [Operators](#operators)
11
+ * [Precedence](#operator-precedence)
12
+ * [Associativity](#operator-associativity)
13
+ * [Categories](#operators-categories): [Main](#operators-categories-main), [Regex](#operators-categories-regex)
14
+ * [Meta](#operators-meta)
15
+ * [Unicode](#operators-utf)
16
+ * [Contextualizers](#operators-context)
17
+ * [Junctions](#operators-junctions)
18
+ * [Sets](#operators-sets)
19
+ * [Smartmatch](#operators-smartmatch)
20
+ * [Files Tests](#operators-file-test)
21
+ * [Quoting](#operators-quoting)
22
+ * [Text Processing](#text-processing)
23
+ * [Quoting Adverbs](text-adverb)
24
+ * [Regex Modifier](#text-regex-modifier)
25
+ * [Metachar](#text-regex-metachar)
26
+ * [Quantifier](#text-regex-quantifier)
27
+ * [Control Chars](#text-control-char)
28
+ * [Escape Sequences](#text-escape-seqences)
29
+ * [Zero-Width Boundaries](#text-boundaries)
30
+ * [Rules](#text-rules)
31
+ * [Match Object Methods](#match-methods)
32
+ * [Flow Control](#flow-control)
33
+ * [Phaser](#flow-phaser)
34
+ * [Jump Commands](#flow-jump)
35
+ * [Conditionals](#flow-conditional)
36
+ * [Loops](#flow-loop)
37
+ * [Routine](#flow-routine): [Types](#flow-routine-type), [Modifier](#flow-routine-modifier), [Trait](#flow-routine-traits), [Parameter Trait](#flow-parameter-traits), [Signature Symbol](#flow-signature-symbols)
38
+ * [Callframe Methods](#flow-callframe-methods)
24
39
25
40
<a id="variables"/>
26
41
@@ -451,10 +466,13 @@ X list `infix:<op>($a; $b; $c)`
451
466
------ ------ ------------------------------- ------------------------
452
467
453
468
469
+ <a id="operators-categories"/>
454
470
455
471
[Categories](#nav-top)
456
472
----------
457
473
474
+ <a id="operators-categories-main"/>
475
+
458
476
### [MAIN](#nav-top) ###
459
477
460
478
These are the categories of the main language
@@ -495,6 +513,7 @@ that can be used to create new categories.
495
513
[`type_declarator:<subset>`](appendix-a-index#type-declarator-category)
496
514
-----------------------------------------------------------------------------------------------------------
497
515
516
+ <a id="operators-categories-regex"/>
498
517
499
518
### [Regex](#nav-top) ###
500
519
@@ -509,6 +528,7 @@ The default [*regex*](appendix-g-glossary#regex) language as stored in
509
528
[`quantifier:sym<*>`](appendix-a-index#quantifier-category)
510
529
------------------------------------------------------------------------
511
530
531
+ <a id="operators-meta"/>
512
532
513
533
[Metaoperators](#nav-top)
514
534
-------------
@@ -534,7 +554,7 @@ if followed by `()`.
534
554
[`Zop`](appendix-a-index#Z-metaop) [zipwith()](appendix-a-index#zipwith) like hyper, but evaluates lazy, `@result = $L[0] op $R[0], $L[1] op $R[1], ...`
535
555
-------------------------------------------- ----------------------------------------- ----------------------------------------------------------
536
556
537
-
557
+ <a id="operators-utf"/>
538
558
539
559
[Unicode operators](#nav-top)
540
560
-----------------
@@ -550,6 +570,7 @@ signs (documented as "Texas Quotes"). [Set ops](#sets) have also UTF-variants.
550
570
«» [\<\< \>\>](appendix-a-index#double-angle-brackets) [**qw**](appendix-a-index#qw-op) with [evaluation](appendix-g-glossary#evaluation) and [quote protection](appendix-g-glossary#quote-protection)
551
571
--- ---------------------- ---------------------------- -----------------------------------------------
552
572
573
+ <a id="operators-context"/>
553
574
554
575
[Contextualizers](#nav-top)
555
576
---------------
@@ -573,7 +594,7 @@ that forcing a [context](appendix-g-glossary#context).
573
594
[`||`](appendix-a-index#pipe-pipe-context) flatten [capture](appendix-g-glossary#capture) object into semicolon list (positional parameter)
574
595
------------------------------------------ ------------------------------- ----------------------------------------------------------------------------------------------
575
596
576
-
597
+ <a id="operators-junctions"/>
577
598
578
599
[Junctions](#nav-top)
579
600
---------
@@ -593,6 +614,7 @@ Junctive Infix Op Prefix Op Operation
593
614
[none](appendix-a-index#none) [NOT](appendix-g-glossary#not) any [True](appendix-a-index#True) if none are True
594
615
---------------------------------- ----------------------------- ---------------------------------- -----------------------------------------------
595
616
617
+ <a id="operators-sets"/>
596
618
597
619
[Sets](#nav-top)
598
620
----
@@ -622,6 +644,7 @@ Set Op UTF CPNR Neg. CPNR Short Expl
622
644
(.) ⊍ 228D b.mul Bag with elements that are in both bags but weight multiplied
623
645
---------------------------------------- ----- ---- ---- ---- ----- -----------------------------------------------------
624
646
647
+ <a id="operators-smartmatch"/>
625
648
626
649
[Smartmatch](#nav-top)
627
650
----------
@@ -699,6 +722,7 @@ Callable [Hash](appendix-a-index#Hash-
699
722
[Any](appendix-a-index#Any-type) [Any](appendix-a-index#Any-type) scalars are identical `$_ === X`
700
723
------------------------------------------- -------------------------------------------- ------------------------------------------ --------------------------------------
701
724
725
+ <a id="operators-file-test"/>
702
726
703
727
[Test Methods](#nav-top)
704
728
------------
@@ -735,6 +759,7 @@ Use it as in `$filename.IO ~~ :X` or `$filename.IO.X`.
735
759
[:k](appendix-a-index#k-test) Bool Path has sticky bit set
736
760
----------------------------- ---- ----------------------------------------------------------
737
761
762
+ <a id="operators-quoting"/>
738
763
739
764
[Quoting Ops](#nav-top)
740
765
-----------
@@ -761,13 +786,15 @@ Op Nonealphanumeric Version Tr
761
786
[quasi {}](appendix-a-index#quasi) [Q](appendix-a-index#Q-op) [:code](appendix-a-index#code-adverb) // [quasiquoting](appendix-g-glossary#quasiquoting)
762
787
--------------------------------- ----------------------------------------- ------------------------------------------------------------------------------------------------------------------------- ---------------------------------- ----------------------------------------------------------
763
788
789
+ <a id="text-processing"/>
764
790
791
+ # [Text Processing](#nav-top)
765
792
766
- [Text Processing](#nav-top)
767
- ===============
768
793
769
- [Quoting Adverbs](#nav-top)
770
- ---------------
794
+ <a id="text-adverbs"/>
795
+
796
+ ## [Quoting Adverbs](#nav-top)
797
+
771
798
772
799
There are a lot more adverbs to
773
800
[fine tune your quoting](tablet-2-basic-syntax#interpolation).
@@ -796,7 +823,7 @@ Short Long
796
823
[:trans](appendix-a-index#trans-adverb) parse as [transliteration](appendix-g-glossary#transliteration)
797
824
--------------------------------- ------------------------------------------------- -------------------------------------------------
798
825
799
-
826
+ <a id="text-regex-modifier"/>
800
827
801
828
[Regex Modifier](#nav-top)
802
829
--------------
@@ -832,6 +859,7 @@ Short Long
832
859
[:P5](appendix-a-index#gP5-modifier) [:Perl5](appendix-a-index#Perl5-modifier) use the Perl 5 Regex syntax
833
860
---------------------------------------- --------------------------------------------------------------------------------------------------------------------- ---------------------------------------------------------------------------------------------------------
834
861
862
+ <a id="text-regex-metachar"/>
835
863
836
864
[Regex Metacharacter](#nav-top)
837
865
-------------------
@@ -857,6 +885,7 @@ Short Long
857
885
[`:=`](appendix-a-index#colon-equal-op) bind the result of a match to a hypothetical variable
858
886
---------------------------------------------------- ----------------------------------------------------------------------------------------------------------
859
887
888
+ <a id="text-regex-quantifier"/>
860
889
861
890
[Quantifier](#nav-top)
862
891
----------
@@ -872,6 +901,7 @@ Short Long
872
901
[`%%`](appendix-a-index#percent-percent-metachar) like %, but allows trailing separator
873
902
------------------------------------------------------------------ -------------------------------------------------------------------------------------------
874
903
904
+ <a id="text-control-char"/>
875
905
876
906
[Control Chars](#nav-top)
877
907
-------------
@@ -891,10 +921,10 @@ and thatswhy also included in the next list.
891
921
`\t` TAB
892
922
----- -----------------
893
923
924
+ <a id="text-escape-seqences">
894
925
926
+ ## [Escape Sequences](#nav-top)
895
927
896
- [Escape Sequences](#nav-top)
897
- ----------------
898
928
899
929
To be used just inside of regexes (rx/.../, m/.../, s/.../.../ and tr/.../.../).
900
930
@@ -929,6 +959,8 @@ To be used just inside of regexes (rx/.../, m/.../, s/.../.../ and tr/.../.../).
929
959
[`\X[ ... ]`](appendix-a-index#backslash-X) anything but the character given in hexadecimal (brackets optional)
930
960
------------------------------------------- -------------------------------------------------------------------
931
961
962
+ <a id="text-boundaries"/>
963
+
932
964
[Zero-Width Boundaries](#nav-top)
933
965
---------------------
934
966
@@ -941,7 +973,7 @@ To negate put a ! in front of the pipe symbol.
941
973
[`<|w>`](appendix-a-index#pipe-w) word boundary aka \<wb\>
942
974
--------------------------------- -------------------------------------------------------------------
943
975
944
-
976
+ <a id="text-rules"/>
945
977
946
978
[Subrules](#nav-top)
947
979
--------
@@ -976,6 +1008,8 @@ regex. They can have prefixes: . (dot) marks a non-capturing subrule,
976
1008
[`<!>`](appendix-a-index#exclamation-subrule) always false
977
1009
--------------------------------------------------------------- -------------------------------------------------
978
1010
1011
+ <a id="match-methods"/>
1012
+
979
1013
[Match Object Methods](#nav-top)
980
1014
--------------------
981
1015
@@ -996,11 +1030,14 @@ submatch
996
1030
-------------- ----------------------------------------------
997
1031
998
1032
999
- [Flow Control](#nav-top)
1000
- ============
1033
+ <a id="flow-control"/>
1034
+
1035
+ # [Flow Control](#nav-top)
1036
+
1037
+ <a id="flow-phaser"/>
1038
+
1039
+ ## [Closure Traits](#nav-top)
1001
1040
1002
- [Closure Traits](#nav-top)
1003
- --------------
1004
1041
1005
1042
aka phasers. Every block can contain special named blocks (some are
1006
1043
only for loops) that are started at certain times. They are traits
@@ -1031,9 +1068,9 @@ also be used within an expression as in `BEGIN my $x = 3 * 3;`.
1031
1068
------------------------------------------------- ------------------------------------------------------------------
1032
1069
1033
1070
1071
+ <a id="flow-jump"/>
1034
1072
1035
- [Jump Commands](#nav-top)
1036
- -------------
1073
+ ## [Jump Commands](#nav-top)
1037
1074
1038
1075
1039
1076
----------------------------------- --------------------------------------------------------------
@@ -1048,9 +1085,9 @@ also be used within an expression as in `BEGIN my $x = 3 * 3;`.
1048
1085
----------------------------------- --------------------------------------------------------------
1049
1086
1050
1087
1088
+ <a id="flow-conditional"/>
1051
1089
1052
- [Conditionals](#nav-top)
1053
- ------------
1090
+ ## [Conditionals](#nav-top)
1054
1091
1055
1092
--------------------------------------- --------------------------------------------------------------------------------------
1056
1093
[if](appendix-a-index#if) when following expression evals in boolean context to True, the block that following after that will be executed
@@ -1065,9 +1102,9 @@ also be used within an expression as in `BEGIN my $x = 3 * 3;`.
1065
1102
[default](appendix-a-index#default) following block will be executed, when no "when" clause was executed
1066
1103
--------------------------------------- --------------------------------------------------------------------------------------
1067
1104
1105
+ <a id="flow-loop"/>
1068
1106
1069
- [Loops](#nav-top)
1070
- -----
1107
+ ## [Loops](#nav-top)
1071
1108
1072
1109
--------------------------------- -----------------------------------------------------------
1073
1110
[loop](appendix-a-index#loop) general (endless) loop, unless used as an C-style-loop, evals following expression into void context
@@ -1078,14 +1115,14 @@ also be used within an expression as in `BEGIN my $x = 3 * 3;`.
1078
1115
[for](appendix-a-index#for ) evals expression into lazy list context and iterates over that list from first to last value, sets each time `$_` (can be combined with **when** as well),
1079
1116
--------------------------------- -----------------------------------------------------------
1080
1117
1118
+ <a id="flow-routine"/>
1081
1119
1082
-
1083
- [Routines](#nav-top)
1084
- --------
1120
+ ## [Routines](#nav-top)
1085
1121
1086
1122
routine definition: \[[scope](ap-b-lookup#scopes)\] \[modifier\]
1087
1123
type \[name\] \[trait\] ([signature](appendix-g-glossary#signature)) { block }
1088
1124
1125
+ <a id="flow-routine-type"/>
1089
1126
1090
1127
### [Routine Types](#nav-top) ###
1091
1128
@@ -1100,7 +1137,7 @@ type \[name\] \[trait\] ([signature](appendix-g-glossary#signature)) { block }
1100
1137
[quasi](appendix-a-index#quasi) block that is compiled to an [AST](appendix-g-glossary#AST) at runtime
1101
1138
----------------------------------------- -------------------------------------------------------------------------------------------------------
1102
1139
1103
-
1140
+ <a id="flow-routine-modifier"/>
1104
1141
1105
1142
### [Routine Modifier](#nav-top) ###
1106
1143
@@ -1110,6 +1147,7 @@ type \[name\] \[trait\] ([signature](appendix-g-glossary#signature)) { block }
1110
1147
[proto](appendix-a-index#proto-routine-modifier) fallback for multi, if no multi signature matches the caller, a proto with same name is executed
1111
1148
------------------------------------------------ -------------------------------------------------------------------------------------------------------
1112
1149
1150
+ <a id="flow-routine-traits"/>
1113
1151
1114
1152
### [Routine Traits](#nav-top) ###
1115
1153
@@ -1131,6 +1169,7 @@ type \[name\] \[trait\] ([signature](appendix-g-glossary#signature)) { block }
1131
1169
[assoc](appendix-a-index#assoc-routine-trait) specifies the [associativity](#operator-associativity) of an operator explicitly as seen here
1132
1170
----------------------------------------------------- -------------------------------------------------------------------------------------
1133
1171
1172
+ <a id="flow-parameter-traits"/>
1134
1173
1135
1174
### [Parameter Traits](#nav-top) ###
1136
1175
@@ -1143,7 +1182,7 @@ type \[name\] \[trait\] ([signature](appendix-g-glossary#signature)) { block }
1143
1182
[parcel](appendix-a-index#parcel-parameter-trait) raw reference, will not be contextualized
1144
1183
------------------------------------------------------ -----------------------------------------------------------------------------
1145
1184
1146
-
1185
+ <a id="flow-signature-symbols"/>
1147
1186
1148
1187
### [Signature Symbols](#nav-top) ###
1149
1188
@@ -1161,8 +1200,10 @@ In routine and block definitions can be also some character with special meaning
1161
1200
[`^`](appendix-a-index#caret-signature) prefix of metaclass methods, `$obj.^methods();` is shortcut for [`$obj.HOW.methods($obj);`](#object-introspection)
1162
1201
-------------------------------------------------------- ------------------------------------------------------------------------------------------------------------------
1163
1202
1164
- [Callframe Methods](#nav-top)
1165
- -----------------
1203
+ <a id="flow-callframe-methods"/>
1204
+
1205
+ ## [Callframe Methods](#nav-top)
1206
+
1166
1207
1167
1208
A callframe object is generated at run-time for each call of a block of code.
1168
1209
If a block of code includes a [**callframe()**](appendix-a-index#callframe) call,
0 commit comments