Translations:Development/KDevelop-PG-Qt Introduction/184/en: Difference between revisions
Appearance
Importing a new version from external source |
(No difference)
|
Latest revision as of 09:55, 10 February 2019
There is rudimentary support for lookahead and so called (our invention) barriers:
⟨regular expression⟩ %la(⟨regular expression⟩); ⟨regular expression⟩ %ba(⟨regular expression⟩);
The first rule will only accept words if they match the first regular expression and are followed by anything matching the expression specified using %la. The second rule will accept words matched by the first regular expression but will never run into a character sequence matching the regex specified by %ba. However, currently only rules with fixed length are allowed in %la and %ba (for example foo|bar, but not qux|garply). When applying the “first longest match” rule the %la/%ba expressions count, too.