aboutsummaryrefslogtreecommitdiff
path: root/pattern.c
AgeCommit message (Collapse)Author
2022-05-14Added :tagBruce Hill
2022-05-12Split backref/named captures into separate concepts for performanceBruce Hill
reasons.
2022-05-05Fix for source code ranges of suffix patternsBruce Hill
2022-05-02Updated Make rules so default is `bp`Bruce Hill
2022-04-30Added tagged definitions: `foo:: blah`Bruce Hill
2022-04-30Simplified things by passing a def argument to next_match instead ofBruce Hill
chaining defs together. Also simplified `..` by just using a lookahead instead of retconning it. Immutability invariants are now enforced better.
2022-04-27Later-chained defs take precedence over more recently chained defsBruce Hill
2022-04-21Made NULL end values default to strlen()Bruce Hill
2021-09-28Hardening utils (added *end param to avoid going past the end ofBruce Hill
unterminated strings)
2021-09-27Removed definitions as a separate type and instead encode that value inBruce Hill
the patterns themselves. This simplifies memory management a lot and speeds up performance.
2021-09-26Refactor of pat_t memory management to use doubly linked lists, andBruce Hill
moving the recursive freeing code from Lua/lbp.c into pattern.c
2021-09-26Minor cleanupsBruce Hill
2021-09-24BugfixBruce Hill
2021-09-23Patterns no longer need files.hBruce Hill
2021-09-23Patterns don't need to reference a separate `start` value anymoreBruce Hill
2021-09-23Moving pattern lifetime tracking off of files and onto its own list ofBruce Hill
allocated pats.
2021-09-23Moved type defs into their own files instead of types.hBruce Hill
2021-09-23API update: made new_pat() internal and added public bp_backref() toBruce Hill
cover that use case
2021-09-23Switched to using an optional typeBruce Hill
2021-09-23Merge branch 'master' into setjmpBruce Hill
2021-09-23Deprecated (!)-errorsBruce Hill
2021-09-23WIP implementation of setjmp/longjmp recoveryBruce Hill
2021-09-21Moving cache logic into match, cleaner next_match() API, and slightlyBruce Hill
less tightly coupled UTF8 API
2021-08-28Style change: added cino=:0 (i.e. case statements on same indentation asBruce Hill
switch). Also fixed issue where $$ would fail to match with trailing newline on file
2021-08-23Add support for {strings}Bruce Hill
2021-08-02Bugfix for postfix operatorsBruce Hill
2021-08-01Cleanup of space/line skipping codeBruce Hill
2021-08-01Changed how definitions workBruce Hill
2021-07-30Added | as alias for \bBruce Hill
2021-07-30Added strict mode for upto operator: ..=AbcBruce Hill
2021-07-30Ergonomic improvement: xcalloc -> new(), xrealloc -> grow()Bruce Hill
2021-07-29Fix for bug in char pattern start posBruce Hill
2021-07-29Tweaks and optimizationsBruce Hill
2021-07-26Performance improvements for cachingBruce Hill
2021-07-26Introduced cache to greatly speed up many use casesBruce Hill
2021-07-19Error reporting bugfixBruce Hill
2021-07-19Made escape sequence handling stricter: no longer supporting arbitraryBruce Hill
characters, only special escapes like \n, hex sequences like \x0a, octal sequences like \012, and backslashes \\
2021-07-19Overhaul of word boundaries/edges. Now they use \b, which is implementedBruce Hill
in C, and the C code understands UTF8 id chars.
2021-07-17Added support for multiple escape sequences: \n,r,tBruce Hill
2021-05-22Minor splint fixesBruce Hill
2021-05-22Fixes for replacements with or without patterns/replacement stringsBruce Hill
2021-05-20Fix for broken escapesBruce Hill
2021-05-20Fixed backslash escape for single utf8 chars.Bruce Hill
2021-05-20Fixes for char sets/ranges and cleanupsBruce Hill
2021-05-20Cleanup/fixBruce Hill
2021-05-20Better codepoint functionalityBruce Hill
2021-05-20Mostly working versionBruce Hill
2021-05-20Removed escape sequences from string pats (use `bp 'line\nl;line'` orBruce Hill
`bp 'line\(nl)line'` or `bp 'line\\nline'` instead)
2021-05-20Added (!) syntax for errors with proper opcode supportBruce Hill
2021-05-19Added ~ and !~ operators as replacements for == and !=Bruce Hill