vpcre: Added 'Non-greedy quantifiers' fix #26579#26582
Conversation
There was a problem hiding this comment.
I want to keep the backwards compatibility with the vlang/pcre module.
I do not see why were the shims for that removed?
They were added in 5b2db04, and are:
pub fn (m Match) get(idx int) ?string {
pub fn (m Match) get_all() []string {
pub fn new_regex(pattern string, _ int) !Regex {
pub fn (r Regex) match_str(text string, start_index int, _ int) ?Match {
Also why was the example edited at all, given that it does not exercise the non greedy qualifiers feature?
Imho it and the shims should be restored, and if needed, another example can be added, that shows the new feature too. I am also perfectly fine for it to be just tested, without an example - a regex engine is a complex thing, and not all of its features can be shown in an example, they just need to be documented/tested.
|
@spytheman 👍 ok I'm not a fan of it but it can be easily implemented, I'll do asap as I'll have few spare time. |
Thank you 🙇🏻 . |
Done 🙇 |
|
Excellent work. |
What's in
*?,+?,??Note: this new feature require more tests in future
This PR should solve the issue #26579
A.I. support:
Gemini 3 Pro Preview