Commit Graph

30 Commits

Author SHA1 Message Date
f271863601 Rename 'pat_t' -> 'bp_pat_t' 2024-05-29 13:12:34 -04:00
31649edc77 Add some fixes and compiler flags 2024-05-28 01:59:03 -04:00
6ce581173f Fix Lua module 2023-05-16 20:05:48 -04:00
3fdd5211d9 Facilitate memory cleanup 2022-10-27 13:24:35 -04:00
e258645a52 Better error handling behavior 2022-10-27 13:17:23 -04:00
2bc0ca7390 Revert "Moving to each_match() API"
This reverts commit 9380a54d7c.
2022-10-27 12:49:31 -04:00
645081f64e Fixed lua to work with new API 2022-10-26 20:26:58 -04:00
9380a54d7c Moving to each_match() API 2022-10-26 20:12:18 -04:00
23c64e386c Changed how tags work, changed Lua API for handling match captures 2022-05-14 22:43:13 -04:00
ca89d65513 Better error handling 2022-05-14 16:01:37 -04:00
892708a651 Cleaned up pattern capture structuring with tagged matches 2022-04-30 18:05:43 -04:00
206e1fa68f Added tagged definitions: foo:: blah 2022-04-30 15:23:02 -04:00
24ed834317 Simplified things by passing a def argument to next_match instead of
chaining defs together. Also simplified `..` by just using a lookahead
instead of retconning it. Immutability invariants are now enforced
better.
2022-04-30 14:19:08 -04:00
e5c0d09893 Added printmatch 2022-04-27 19:13:32 -04:00
911827fac3 Removed definitions as a separate type and instead encode that value in
the patterns themselves. This simplifies memory management a lot and
speeds up performance.
2021-09-27 20:36:10 -07:00
a96284615b Added __concat and __div 2021-09-26 14:34:06 -07:00
6b29503e95 Added :getsource() method 2021-09-26 14:23:24 -07:00
9983e2444a Switched pattern objects to use a full userdata instead of a table 2021-09-26 13:43:39 -07:00
77d9007a88 Refactor of pat_t memory management to use doubly linked lists, and
moving the recursive freeing code from Lua/lbp.c into pattern.c
2021-09-26 13:12:02 -07:00
3fe77cbf3e :eachmatch() -> :matches() 2021-09-25 19:05:15 -07:00
fb1840e07a Improved lua API, including re.compile() and re.eachmatch() 2021-09-25 19:03:56 -07:00
270a0a47c4 Minor cleanup 2021-09-25 14:53:34 -07:00
cfc53ea643 Overhaul of lua API to use tables 2021-09-24 22:55:39 -07:00
3de6de1ffa Added builtins for lua library 2021-09-23 21:19:39 -07:00
3a2492d584 WIP: working line breaks, formatting, etc. All seems functional, but a
bit messy
2021-09-23 20:51:04 -07:00
04eb92153f WIP 2021-09-23 17:31:21 -07:00
1460e6d940 Updated lua code 2021-09-23 15:42:19 -07:00
89c5888dd6 Switched to using an optional type 2021-09-23 14:38:46 -07:00
55ff8ec663 WIP 2021-09-23 13:33:22 -07:00
7122dcdc81 Added Lua bindings 2021-09-22 23:51:34 -07:00