Opened 17 years ago
Closed 17 years ago
#519 closed Bugs (Invalid)
Problems in regex in MS Visual Studio.NET 2005
| Reported by: | mbobka | Owned by: | John Maddock |
|---|---|---|---|
| Milestone: | Component: | regex | |
| Version: | None | Severity: | |
| Keywords: | Cc: |
Description
When I try to run this code:
#include "stdafx.h"
#define BOOST_REGEX_MATCH_EXTRA
#include <boost\regex.hpp>
int _tmain(int argc, _TCHAR* argv[])
{
boost::regex re( "^(?:(.+?),)*(.+?)$" );
boost::cmatch matches;
if( boost::regex_match( "hello", matches,
re ) ) {
for( boost::cmatch::iterator pos =
matches.begin() + 1; pos != matches.end(); pos++ ) {
}
return 1;
}
return 0;
}
compiled by Visual Studio.NET 2005, assertion will be
failed at
boost_1_33_1_beta\boost/regex/v4/match_results.hpp,
line 282 (Assertion failed: pos+2 < m_subs.size()).
If I undefine BOOST_REGEX_MATCH_EXTRA, then all is OK.
Note:
See TracTickets
for help on using tickets.
