fix trac 9544: gcc 4.9.0 -std=c++1y breakage

This is GCC bug PR C++/59681 but the Boost fix is trivial and the GCC
one is (probably) not.

See: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59681
This commit is contained in:
Peter A. Bigot
2014-01-04 22:03:10 -06:00
parent a3075dd98f
commit 1b8322ecbf
2 changed files with 2 additions and 2 deletions

View File

@ -971,7 +971,7 @@ bool basic_regex_parser<charT, traits>::parse_repeat(std::size_t low, std::size_
// the last state was a literal with more than one character, split it in two:
re_literal* lit = static_cast<re_literal*>(this->m_last_state);
charT c = (static_cast<charT*>(static_cast<void*>(lit+1)))[lit->length - 1];
--(lit->length);
lit->length -= 1;
// now append new state:
lit = static_cast<re_literal*>(this->append_state(syntax_element_literal, sizeof(re_literal) + sizeof(charT)));
lit->length = 1;