Boost C++ Libraries: Ticket #6735: Regex pattern matching with wrong string https://svn.boost.org/trac10/ticket/6735 <p> Hi, I am comparing the regular expression "<a class="source" href="https://svn.boost.org/trac10/log/?revs=0-9">[0-9]</a>+" with the string "1.2" I am expecting the comparison to be a failure as part of the following check in <a class="missing wiki">ConfigReader</a>.cpp </p> <p> if (false == var.<a class="missing wiki">CheckValue</a>(tValue)) { </p> <blockquote> <p> throw(<a class="missing wiki">FormatDisallowed</a>(name, var.m_Allowed, tValue)); </p> </blockquote> <p> } </p> <p> However, looks like <a class="missing wiki">CheckValue</a>() is returning a success -&gt; which is incorrect. I added a print after the checkValue to verify it (which got hit) </p> <p> Same is the case for "<a class="source" href="https://svn.boost.org/trac10/log/?revs=0-9">[0-9]</a>+" and "123abc" Please let me know if I am missing something OR is it a known issue. </p> <p> thanks, Adarsh. </p> <p> Tried using gdb. Results follows: ======================== </p> <p> (gdb) p var.m_Allowed $12 = { </p> <blockquote> <p> static npos = 4294967295, _M_dataplus = { </p> <blockquote> <p> &lt;std::allocator&lt;char&gt;&gt; = { </p> <blockquote> <p> &lt;<span class="underline">gnu_cxx::new_allocator&lt;char&gt;&gt; = {&lt;No data fields&gt;}, &lt;No data fields&gt;}, </span></p> </blockquote> <p> members of std::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;::_Alloc_hider: _M_p = 0x9b98f14 "<a class="source" href="https://svn.boost.org/trac10/log/?revs=0-9">[0-9]</a>+" </p> </blockquote> <p> } </p> </blockquote> <p> } (gdb) p tValue $13 = { </p> <blockquote> <p> static npos = 4294967295, _M_dataplus = { </p> <blockquote> <p> &lt;std::allocator&lt;char&gt;&gt; = { </p> <blockquote> <p> &lt;<span class="underline">gnu_cxx::new_allocator&lt;char&gt;&gt; = {&lt;No data fields&gt;}, &lt;No data fields&gt;}, </span></p> </blockquote> <p> members of std::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;::_Alloc_hider: _M_p = 0x9ba54d4 "1.2" </p> </blockquote> <p> } </p> </blockquote> <p> } </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/6735 Trac 1.4.3 anonymous Tue, 27 Mar 2012 09:41:02 GMT severity changed https://svn.boost.org/trac10/ticket/6735#comment:1 https://svn.boost.org/trac10/ticket/6735#comment:1 <ul> <li><strong>severity</strong> <span class="trac-field-old">Problem</span> → <span class="trac-field-new">Not Applicable</span> </li> </ul> <p> Did some more digging and found out that this is not a bug. </p> <p> Sorry for the false alarm </p> Ticket viboes Mon, 28 May 2012 17:22:16 GMT component changed; owner set https://svn.boost.org/trac10/ticket/6735#comment:2 https://svn.boost.org/trac10/ticket/6735#comment:2 <ul> <li><strong>owner</strong> set to <span class="trac-author">John Maddock</span> </li> <li><strong>component</strong> <span class="trac-field-old">None</span> → <span class="trac-field-new">regex</span> </li> </ul> Ticket John Maddock Mon, 28 May 2012 17:50:13 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/6735#comment:3 https://svn.boost.org/trac10/ticket/6735#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">invalid</span> </li> </ul> Ticket