From 8728bcf941f6d17c4364db5d361364d2e2d7d01d Mon Sep 17 00:00:00 2001 From: Kyryl Melekhin Date: Sat, 2 Oct 2021 09:37:09 +0000 Subject: [PATCH] readme: misc for next opts --- README | 4 ++-- pike.c | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README b/README index 80faac2..2d92068 100644 --- a/README +++ b/README @@ -29,7 +29,7 @@ to that. * Matcher does not take size of string as param, it checks for '\0' instead, so that the user does not need to waste time taking strlen() * Highly optimized source code, probably 2x faster than re1.5 -* Support for quoted chars in regex. +* Support for quoted chars in regex. Escapes in brackets. * Support for ^, $ assertions in regex. * Support for repetition operator {n} and {n,m}. * Support for Unicode (UTF-8). @@ -45,7 +45,7 @@ the pcre "\b" which can be used both in front or back of the word, because there no distinction, it makes the implementation potentially even uglier. * Assert flags like REG_ICASE,REG_NOTEOL,REG_NOTBOL and lookahead inside negated bracket are implemented here (also shows use case in real world project): -https://github.com/kyx0r/neatvi/blob/pikevm/regex.c +https://github.com/kyx0r/nextvi/blob/master/regex.c NOTES ===== diff --git a/pike.c b/pike.c index 5fc7dfd..6bd5538 100644 --- a/pike.c +++ b/pike.c @@ -185,6 +185,9 @@ void re_dumpcode(rcode *prog) printf("Unilen: %d, insts: %d\n", prog->unilen, prog->len); } +/* next todo: crack and factor out this recursion, +no recursion will allow to make a meta macro out +of this, such that re_sizecode() becomes efficient */ static int _compilecode(const char **re_loc, rcode *prog, int sizecode) { const char *re = *re_loc;