diff options
| author | EuAndreh <eu@euandre.org> | 2025-07-15 20:43:57 -0300 |
|---|---|---|
| committer | EuAndreh <eu@euandre.org> | 2025-07-15 20:43:57 -0300 |
| commit | 43946ca0c9e19f904b7f763b9dc590d8095e6472 (patch) | |
| tree | a5549d003fff4459876b23539e428fc42c007508 /Makefile | |
| parent | tests/paca.mjs (test_shouldConcat): Also hoist import, definition and positio... (diff) | |
| download | paca-43946ca0c9e19f904b7f763b9dc590d8095e6472.tar.gz paca-43946ca0c9e19f904b7f763b9dc590d8095e6472.tar.xz | |
Support tokenizing `^` and `$` anchors
* src/paca.mjs
(ANCHOR_FNS): Add simple handlers for ^ and $ anchors, that only look
for the position of the character in the pattern as validation
during tokenization.
(isAnchor): Add simple boolean function to identify anchor characters.
(tokenizeRegexStep): Include check if character `isAnchor()`, and call
the appropriate `ANCHOR_FNS[char]` when true.
* tests/paca.mjs
(test_ANCHOR_FNS): Add test with 4 cases - 2 for success and 2 for
errors for ^ and $.
(test_isAnchor): Add obligatory simple test cases.
(test_tokenizeRegexStep): Include test case for tokenizing patterns
with character class.
Diffstat (limited to 'Makefile')
0 files changed, 0 insertions, 0 deletions
