mirror of
https://github.com/janet-lang/janet
synced 2025-10-30 07:03:02 +00:00
Add Peg combinators 'to' and 'thru'.
Inpsired by the REBOL operators of the same name, these combinators match bytes up to or inculding a given pattern. (to patt) is (almost) equalivalent to (any (if-not patt 1)), and (thru patt) is equivalent to (* (to patt) patt). The one difference is that if the end of the input is reached and patt is not matched, the entire pattern does not match.
This commit is contained in:
@@ -23,7 +23,7 @@ static int num_array_gc(void *p, size_t s) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
int num_array_get(void *p, Janet key, Janet *out);
|
||||
int num_array_get(void *p, Janet key, Janet *out);
|
||||
void num_array_put(void *p, Janet key, Janet value);
|
||||
|
||||
static const JanetAbstractType num_array_type = {
|
||||
|
||||
Reference in New Issue
Block a user