On Sat, Apr 26, 2014 at 10:50 AM, Jonathan Wakely wrote:
> This patch is OK, thanks very much.
Committed. Thanks!
--
Regards,
Tim Shen
On 25/04/14 20:50 -0400, Tim Shen wrote:
* include/bits/regex.tcc (__regex_algo_impl<>): Remove
_GLIBCXX_REGEX_DFS_QUANTIFIERS_LIMIT and use
_GLIBCXX_REGEX_USE_THOMPSON_NFA instead.
* include/bits/regex_automaton.h: Remove quantifier counting variable.
* i
On Fri, Apr 25, 2014 at 7:56 PM, Jonathan Wakely wrote:
> That's why I thought #ifndef would work, not #ifdef
Oh I didn't notice that. Now they are equivalent.
--
Regards,
Tim Shen
commit cb39603d6df4763e95a697792e7b45179994f096
Author: tim
Date: Fri Apr 25 01:49:31 2014 -0400
2014-04-
On 25/04/14 18:14 -0400, Tim Shen wrote:
On Fri, Apr 25, 2014 at 5:14 PM, Jonathan Wakely wrote:
I wonder if this would be simpler to read like this:
if (!__re._M_automaton->_M_has_backref
#ifndef _GLIBCXX_REGEX_USE_THOMPSON_NFA
&& __policy == _RegexExecutorPolicy::_S_alterna
On Fri, Apr 25, 2014 at 5:14 PM, Jonathan Wakely wrote:
> I wonder if this would be simpler to read like this:
>
>if (!__re._M_automaton->_M_has_backref
> #ifndef _GLIBCXX_REGEX_USE_THOMPSON_NFA
>&& __policy == _RegexExecutorPolicy::_S_alternate
> #endif
> )
I don't
--- a/libstdc++-v3/include/bits/regex.tcc
+++ b/libstdc++-v3/include/bits/regex.tcc
@@ -28,12 +28,12 @@
* Do not attempt to use it directly. @headername{regex}
*/
-// See below __regex_algo_impl to get what this is talking about. The default
-// value 1 indicated a conservative optimization wi
We used _GLIBCXX_REGEX_DFS_QUANTIFIERS_LIMIT to control which
algorithm we should use; so when compiling a regex, the number of
quantifiers(*, +, ?) will be counted and will be used for the
algorithm switching.
However, I do think give user the manual switch may make things
simpler: _GLIBCXX_REGEX