Darryl Abbate
Darryl Abbate
The named capture groups can be extracted from a compiled pattern (`pcre2_code *`) via [`pcre2_pattern_info()`](https://www.pcre.org/current/doc/html/pcre2_pattern_info.html). - `PCRE2_INFO_NAMETABLE` returns a pointer to the first entry of the "name table" (`PCRE2_SPTR`) -...
> Should look closely at the PCRE2 spec for duplicated group names before doing any optimzations with the number name mapping. --- > In an attempt to reduce confusion, PCRE2...
Probably makes sense to implement #22 first and see if the methodolgy can be applied to interpolated string expressions.
`$...` would be available, making regex literals resemble Perl very closely. Though it's not clear how something like `$1` should be handled.
Note that either this feature or some kind of builtin function (`regex(pattern[,flags])`?) needs to exist to provide full capability of dynamically-created regexes. While regexes can be implicitly created at runtime...
Note: this should be as simple as returning the top of the stack, or $n$ elements from the stack if multivals are ever supported (cc #25).
Thanks for the issue. I'm aware of the egregious memory leaks. Many of these are simple fixes (e.g. the program being read into memory). I've just been too focused on...
Note that whenever closures are implemented (#22), `sort()` should be refactored to take a user-defined function as an optional argument