=item C<anchored(TYPE)>
If the pattern may match only at a handful of places, with C<TYPE>
-being C<BOL>, C<MBOL>, or C<GPOS>. See the table below.
+being C<SBOL>, C<MBOL>, or C<GPOS>. See the table below.
=back
=head2 Types of Nodes
-Here are the possible types, with short descriptions:
+Here are the current possible types, with short descriptions:
=for comment
This table is generated by regen/regcomp.pl. Any changes made here
END no End of program.
SUCCEED no Return from a subroutine, basically.
- # Anchors:
+ # Line Start Anchors:
+ SBOL no Match "" at beginning of line: /^/, /\A/
+ MBOL no Same, assuming multiline: /^/m
- BOL no Match "" at beginning of line.
- MBOL no Same, assuming multiline.
- SBOL no Same, assuming singleline.
- EOS no Match "" at end of string.
- EOL no Match "" at end of line.
- MEOL no Same, assuming multiline.
- SEOL no Same, assuming singleline.
+ # Line End Anchors:
+ SEOL no Match "" at end of line: /$/
+ MEOL no Same, assuming multiline: /$/m
+ EOS no Match "" at end of string: /\z/
+
+ # Match Start Anchors:
+ GPOS no Matches where last m//g left off.
+
+ # Word Boundary Opcodes:
BOUND no Match "" at any word boundary using native
- charset semantics for non-utf8
+ charset rules for non-utf8
BOUNDL no Match "" at any locale word boundary
BOUNDU no Match "" at any word boundary using Unicode
- semantics
+ rules
BOUNDA no Match "" at any word boundary using ASCII
- semantics
+ rules
NBOUND no Match "" at any word non-boundary using
- native charset semantics for non-utf8
+ native charset rules for non-utf8
NBOUNDL no Match "" at any locale word non-boundary
NBOUNDU no Match "" at any word non-boundary using
- Unicode semantics
+ Unicode rules
NBOUNDA no Match "" at any word non-boundary using
- ASCII semantics
- GPOS no Matches where last m//g left off.
+ ASCII rules
# [Special] alternatives:
-
REG_ANY no Match any one character (except newline).
SANY no Match any one character.
CANY no Match any one byte.
- ANYOF sv Match character in (or not in) this class,
+ ANYOF sv 1 Match character in (or not in) this class,
single char match only
- ANYOF_SYNTHETIC sv Synthetic start class
+ # POSIX Character Classes:
POSIXD none Some [[:class:]] under /d; the FLAGS field
gives which one
POSIXL none Some [[:class:]] under /l; the FLAGS field
#
BRANCH node Match this alternative, or the next...
- # Back pointer
-
- # BACK Normal "next" pointers all implicitly point forward;
- # BACK exists to make loop structures possible.
- # not used
- BACK no Match "", "next" ptr points backward.
-
# Literals
EXACT str Match this string (preceded by length).
# Loops
# STAR,PLUS '?', and complex '*' and '+', are implemented as
- # circular BRANCH structures using BACK. Simple cases
+ # circular BRANCH structures. Simple cases
# (one character per match) are implemented with STAR
# and PLUS for speed and to minimize recursive plunges.
#
REF num 1 Match some already matched string
REFF num 1 Match already matched string, folded using
- native charset semantics for non-utf8
+ native charset rules for non-utf8
REFFL num 1 Match already matched string, folded in loc.
REFFU num 1 Match already matched string, folded using
- unicode semantics for non-utf8
+ unicode rules for non-utf8
REFFA num 1 Match already matched string, folded using
- unicode semantics for non-utf8, no mixing
- ASCII, non-ASCII
+ unicode rules for non-utf8, no mixing ASCII,
+ non-ASCII
# Named references. Code in regcomp.c assumes that these all are after
# the numbered references
NREF no-sv 1 Match some already matched string
NREFF no-sv 1 Match already matched string, folded using
- native charset semantics for non-utf8
+ native charset rules for non-utf8
NREFFL no-sv 1 Match already matched string, folded in loc.
NREFFU num 1 Match already matched string, folded using
- unicode semantics for non-utf8
+ unicode rules for non-utf8
NREFFA num 1 Match already matched string, folded using
- unicode semantics for non-utf8, no mixing
- ASCII, non-ASCII
+ unicode rules for non-utf8, no mixing ASCII,
+ non-ASCII
+
+ # Support for long RE
+ LONGJMP off 1 1 Jump far away.
+ BRANCHJ off 1 1 BRANCH with long offset.
+ # Special Case Regops
IFMATCH off 1 2 Succeeds if the following matches.
UNLESSM off 1 2 Fails if the following matches.
SUSPEND off 1 1 "Independent" sub-RE.
IFTHEN off 1 1 Switch, should be preceded by switcher.
GROUPP num 1 Whether the group matched.
- # Support for long RE
-
- LONGJMP off 1 1 Jump far away.
- BRANCHJ off 1 1 BRANCH with long offset.
-
# The heavy worker
- EVAL evl 1 Execute some Perl code.
+ EVAL evl/flags Execute some Perl code.
+ 2L
# Modifiers