Boost logo

Boost :

From: John Maddock (john_at_[hidden])
Date: 2004-04-08 07:41:57

> I noticed that the newest regex version no longer supports non-greedy
repeats "+?" in match_posix mode. What was the rationale for >this? Is it
possible to re-enable non-greedy repeats? As far as I could test, it's not
sufficient to modify the syntax check around >regex_compile.hpp:1794; regex
"a+?" would be valid but matches "aaa" on string "-aaa-" instead of "a".

It is deliberate, non-greedy repeats don't really fit into the POSIX
matching philosophy, where repeats are neither greedy not non-greedy, rather
it's parenthesis that determine what the best match is.


Boost list run by bdawes at, gregod at, cpdaniel at, john at