Index: boost/regex/v4/basic_regex_creator.hpp =================================================================== --- boost/regex/v4/basic_regex_creator.hpp (revision 84007) +++ boost/regex/v4/basic_regex_creator.hpp (working copy) @@ -738,14 +738,14 @@ case syntax_element_long_set_rep: // set the state_id of this repeat: static_cast(state)->state_id = m_repeater_id++; - // fall through: + BOOST_FALLTHROUGH; case syntax_element_alt: std::memset(static_cast(state)->_map, 0, sizeof(static_cast(state)->_map)); static_cast(state)->can_be_null = 0; - // fall through: + BOOST_FALLTHROUGH; case syntax_element_jump: static_cast(state)->alt.p = getaddress(static_cast(state)->alt.i, state); - // fall through again: + BOOST_FALLTHROUGH; default: if(state->next.i) state->next.p = getaddress(state->next.i, state); @@ -877,6 +877,7 @@ } } } + break; default: break; } @@ -941,7 +942,7 @@ e.raise(); } } - // fall through: + BOOST_FALLTHROUGH; default: state = state->next.p; } @@ -1153,13 +1154,14 @@ break; } m_recursion_checks[recursion_sub] = true; - // fall through, can't handle nested recursion here... + // can't handle nested recursion here... + BOOST_FALLTHROUGH; } case syntax_element_backref: // can be null, and any character can match: if(pnull) *pnull |= mask; - // fall through: + BOOST_FALLTHROUGH; case syntax_element_wild: { // can't be null, any character can match: @@ -1359,7 +1361,7 @@ state = state->next.p->next.p; break; } - // otherwise fall through: + BOOST_FALLTHROUGH; default: state = state->next.p; } @@ -1456,6 +1458,7 @@ if(state_id <= sizeof(m_bad_repeats) * CHAR_BIT) m_bad_repeats |= (one << state_id); } + break; default: break; } @@ -1537,7 +1540,7 @@ case syntax_element_long_set_rep: if(this->m_has_backrefs == 0) static_cast(state)->leading = true; - // fall through: + BOOST_FALLTHROUGH; default: return; } Index: boost/regex/v4/basic_regex_parser.hpp =================================================================== --- boost/regex/v4/basic_regex_parser.hpp (revision 84007) +++ boost/regex/v4/basic_regex_parser.hpp (working copy) @@ -369,7 +369,7 @@ while((m_position != m_end) && !is_separator(*m_position++)){} return true; } - // Otherwise fall through: + BOOST_FALLTHROUGH; default: result = parse_literal(); break; @@ -623,7 +623,7 @@ { case 'w': negate = false; - // fall through: + BOOST_FALLTHROUGH; case 'W': { basic_char_set char_set; @@ -640,7 +640,7 @@ } case 's': negate = false; - // fall through: + BOOST_FALLTHROUGH; case 'S': return add_emacs_code(negate); case 'c': @@ -672,7 +672,7 @@ { case regex_constants::escape_type_not_class: negate = true; - // fall through: + BOOST_FALLTHROUGH; case regex_constants::escape_type_class: { escape_type_class_jump: @@ -742,7 +742,7 @@ break; case regex_constants::escape_type_not_property: negate = true; - // fall through: + BOOST_FALLTHROUGH; case regex_constants::escape_type_property: { ++m_position; @@ -901,7 +901,7 @@ case regex_constants::escape_type_control_v: if(0 == (this->flags() & (regbase::main_option_type | regbase::no_perl_ex))) goto escape_type_class_jump; - // fallthrough: + BOOST_FALLTHROUGH; default: this->append_literal(unescape_character()); break; @@ -1959,7 +1959,7 @@ { case regex_constants::syntax_or: m_mark_reset = m_mark_count; - // fall through: + BOOST_FALLTHROUGH; case regex_constants::syntax_colon: // // a non-capturing mark: Index: boost/regex/v4/regex_format.hpp =================================================================== --- boost/regex/v4/regex_format.hpp (revision 84007) +++ boost/regex/v4/regex_format.hpp (working copy) @@ -283,7 +283,8 @@ format_perl(); break; } - // fall through, not a special character: + // not a special character: + BOOST_FALLTHROUGH; default: put(*m_position); ++m_position; @@ -354,7 +355,7 @@ case '{': have_brace = true; ++m_position; - // fall through.... + BOOST_FALLTHROUGH; default: // see if we have a number: {