Ticket #8408: boost-fallthrough.diff
File boost-fallthrough.diff, 30.8 KB (added by , 10 years ago) |
---|
-
boost/config/compiler/clang.hpp
38 38 # define BOOST_SYMBOL_VISIBLE __attribute__((__visibility__("default"))) 39 39 #endif 40 40 41 // 42 // The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through 43 // between switch labels. 44 // 45 #if __cplusplus >= 201103L && defined(__has_warning) 46 # if __has_feature(cxx_attributes) && __has_warning("-Wimplicit-fallthrough") 47 # define BOOST_FALLTHROUGH [[clang::fallthrough]] 48 # endif 49 #endif 50 41 51 #if !__has_feature(cxx_auto_type) 42 52 # define BOOST_NO_CXX11_AUTO_DECLARATIONS 43 53 # define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS -
boost/config/suffix.hpp
885 885 #endif 886 886 887 887 // 888 // Helper macro BOOST_FALLTHROUGH 889 // Fallback definition of BOOST_FALLTHROUGH macro used to mark intended 890 // fall-through between case labels in a switch statement. 891 // 892 #ifndef BOOST_FALLTHROUGH 893 # define BOOST_FALLTHROUGH do {} while(0) 894 #endif 895 896 // 888 897 // constexpr workarounds 889 898 // 890 899 #if defined(BOOST_NO_CXX11_CONSTEXPR) -
boost/container/detail/utilities.hpp
1055 1055 ::memcpy(short_ptr, stora_ptr, sizeof_storage); 1056 1056 large_ptr += sizeof_storage; 1057 1057 short_ptr += sizeof_storage; 1058 BOOST_FALLTHROUGH; 1058 1059 case 3: 1059 1060 ::memcpy(stora_ptr, large_ptr, sizeof_storage); 1060 1061 ::memcpy(large_ptr, short_ptr, sizeof_storage); 1061 1062 ::memcpy(short_ptr, stora_ptr, sizeof_storage); 1062 1063 large_ptr += sizeof_storage; 1063 1064 short_ptr += sizeof_storage; 1065 BOOST_FALLTHROUGH; 1064 1066 case 2: 1065 1067 ::memcpy(stora_ptr, large_ptr, sizeof_storage); 1066 1068 ::memcpy(large_ptr, short_ptr, sizeof_storage); 1067 1069 ::memcpy(short_ptr, stora_ptr, sizeof_storage); 1068 1070 large_ptr += sizeof_storage; 1069 1071 short_ptr += sizeof_storage; 1072 BOOST_FALLTHROUGH; 1070 1073 case 1: 1071 1074 ::memcpy(stora_ptr, large_ptr, sizeof_storage); 1072 1075 ::memcpy(large_ptr, short_ptr, sizeof_storage); -
boost/date_time/time_facet.hpp
866 866 break; 867 867 // %s is the same as %S%f so we drop through into %f 868 868 } 869 BOOST_FALLTHROUGH; 869 870 case 'f': 870 871 { 871 872 // check for decimal, check special_values if missing … … 1135 1136 break; 1136 1137 // %s is the same as %S%f so we drop through into %f 1137 1138 } 1139 BOOST_FALLTHROUGH; 1138 1140 case 'f': 1139 1141 { 1140 1142 // check for decimal, check SV if missing -
boost/format/parsing.hpp
267 267 switch ( wrap_narrow(fac, *start, 0) ) { 268 268 case 'X': 269 269 fpar->fmtstate_.flags_ |= std::ios_base::uppercase; 270 BOOST_FALLTHROUGH; 270 271 case 'p': // pointer => set hex. 271 272 case 'x': 272 273 fpar->fmtstate_.flags_ &= ~std::ios_base::basefield; … … 280 281 281 282 case 'E': 282 283 fpar->fmtstate_.flags_ |= std::ios_base::uppercase; 284 BOOST_FALLTHROUGH; 283 285 case 'e': 284 286 fpar->fmtstate_.flags_ &= ~std::ios_base::floatfield; 285 287 fpar->fmtstate_.flags_ |= std::ios_base::scientific; … … 291 293 case 'f': 292 294 fpar->fmtstate_.flags_ &= ~std::ios_base::floatfield; 293 295 fpar->fmtstate_.flags_ |= std::ios_base::fixed; 296 BOOST_FALLTHROUGH; 294 297 case 'u': 295 298 case 'd': 296 299 case 'i': -
boost/iostreams/code_converter.hpp
393 393 394 394 switch (result) { 395 395 case std::codecvt_base::partial: 396 partial = true; // Fall through. 396 partial = true; 397 BOOST_FALLTHROUGH; 397 398 case std::codecvt_base::ok: 398 399 total = static_cast<std::streamsize>(nint - s); 399 400 break; -
boost/locale/utf.hpp
222 222 if (!is_trail(tmp)) 223 223 return illegal; 224 224 c = (c << 6) | ( tmp & 0x3F); 225 BOOST_FALLTHROUGH; 225 226 case 2: 226 227 if(BOOST_LOCALE_UNLIKELY(p==e)) 227 228 return incomplete; … … 229 230 if (!is_trail(tmp)) 230 231 return illegal; 231 232 c = (c << 6) | ( tmp & 0x3F); 233 BOOST_FALLTHROUGH; 232 234 case 1: 233 235 if(BOOST_LOCALE_UNLIKELY(p==e)) 234 236 return incomplete; … … 272 274 switch(trail_size) { 273 275 case 3: 274 276 c = (c << 6) | ( static_cast<unsigned char>(*p++) & 0x3F); 277 BOOST_FALLTHROUGH; 275 278 case 2: 276 279 c = (c << 6) | ( static_cast<unsigned char>(*p++) & 0x3F); 280 BOOST_FALLTHROUGH; 277 281 case 1: 278 282 c = (c << 6) | ( static_cast<unsigned char>(*p++) & 0x3F); 279 283 } -
boost/regex/v4/basic_regex_creator.hpp
738 738 case syntax_element_long_set_rep: 739 739 // set the state_id of this repeat: 740 740 static_cast<re_repeat*>(state)->state_id = m_repeater_id++; 741 // fall through:741 BOOST_FALLTHROUGH; 742 742 case syntax_element_alt: 743 743 std::memset(static_cast<re_alt*>(state)->_map, 0, sizeof(static_cast<re_alt*>(state)->_map)); 744 744 static_cast<re_alt*>(state)->can_be_null = 0; 745 // fall through:745 BOOST_FALLTHROUGH; 746 746 case syntax_element_jump: 747 747 static_cast<re_jump*>(state)->alt.p = getaddress(static_cast<re_jump*>(state)->alt.i, state); 748 // fall through again:748 BOOST_FALLTHROUGH; 749 749 default: 750 750 if(state->next.i) 751 751 state->next.p = getaddress(state->next.i, state); … … 877 877 } 878 878 } 879 879 } 880 break; 880 881 default: 881 882 break; 882 883 } … … 941 942 e.raise(); 942 943 } 943 944 } 944 // fall through:945 BOOST_FALLTHROUGH; 945 946 default: 946 947 state = state->next.p; 947 948 } … … 1153 1154 break; 1154 1155 } 1155 1156 m_recursion_checks[recursion_sub] = true; 1156 // fall through, can't handle nested recursion here... 1157 // can't handle nested recursion here... 1158 BOOST_FALLTHROUGH; 1157 1159 } 1158 1160 case syntax_element_backref: 1159 1161 // can be null, and any character can match: 1160 1162 if(pnull) 1161 1163 *pnull |= mask; 1162 // fall through:1164 BOOST_FALLTHROUGH; 1163 1165 case syntax_element_wild: 1164 1166 { 1165 1167 // can't be null, any character can match: … … 1359 1361 state = state->next.p->next.p; 1360 1362 break; 1361 1363 } 1362 // otherwise fall through:1364 BOOST_FALLTHROUGH; 1363 1365 default: 1364 1366 state = state->next.p; 1365 1367 } … … 1456 1458 if(state_id <= sizeof(m_bad_repeats) * CHAR_BIT) 1457 1459 m_bad_repeats |= (one << state_id); 1458 1460 } 1461 break; 1459 1462 default: 1460 1463 break; 1461 1464 } … … 1537 1540 case syntax_element_long_set_rep: 1538 1541 if(this->m_has_backrefs == 0) 1539 1542 static_cast<re_repeat*>(state)->leading = true; 1540 // fall through:1543 BOOST_FALLTHROUGH; 1541 1544 default: 1542 1545 return; 1543 1546 } -
boost/regex/v4/basic_regex_parser.hpp
369 369 while((m_position != m_end) && !is_separator(*m_position++)){} 370 370 return true; 371 371 } 372 // Otherwise fall through:372 BOOST_FALLTHROUGH; 373 373 default: 374 374 result = parse_literal(); 375 375 break; … … 623 623 { 624 624 case 'w': 625 625 negate = false; 626 // fall through:626 BOOST_FALLTHROUGH; 627 627 case 'W': 628 628 { 629 629 basic_char_set<charT, traits> char_set; … … 640 640 } 641 641 case 's': 642 642 negate = false; 643 // fall through:643 BOOST_FALLTHROUGH; 644 644 case 'S': 645 645 return add_emacs_code(negate); 646 646 case 'c': … … 672 672 { 673 673 case regex_constants::escape_type_not_class: 674 674 negate = true; 675 // fall through:675 BOOST_FALLTHROUGH; 676 676 case regex_constants::escape_type_class: 677 677 { 678 678 escape_type_class_jump: … … 742 742 break; 743 743 case regex_constants::escape_type_not_property: 744 744 negate = true; 745 // fall through:745 BOOST_FALLTHROUGH; 746 746 case regex_constants::escape_type_property: 747 747 { 748 748 ++m_position; … … 901 901 case regex_constants::escape_type_control_v: 902 902 if(0 == (this->flags() & (regbase::main_option_type | regbase::no_perl_ex))) 903 903 goto escape_type_class_jump; 904 // fallthrough:904 BOOST_FALLTHROUGH; 905 905 default: 906 906 this->append_literal(unescape_character()); 907 907 break; … … 1959 1959 { 1960 1960 case regex_constants::syntax_or: 1961 1961 m_mark_reset = m_mark_count; 1962 // fall through:1962 BOOST_FALLTHROUGH; 1963 1963 case regex_constants::syntax_colon: 1964 1964 // 1965 1965 // a non-capturing mark: -
boost/regex/v4/regex_format.hpp
283 283 format_perl(); 284 284 break; 285 285 } 286 // fall through, not a special character: 286 // not a special character: 287 BOOST_FALLTHROUGH; 287 288 default: 288 289 put(*m_position); 289 290 ++m_position; … … 354 355 case '{': 355 356 have_brace = true; 356 357 ++m_position; 357 // fall through....358 BOOST_FALLTHROUGH; 358 359 default: 359 360 // see if we have a number: 360 361 { -
boost/statechart/simple_state.hpp
527 527 { 528 528 pContext_->set_outermost_unstable_state( 529 529 pOutermostUnstableState ); 530 // fall through to next case intended530 BOOST_FALLTHROUGH; 531 531 } 532 532 else 533 533 { -
boost/wave/util/flex_string.hpp
139 139 case 0: 140 140 while (b != e) 141 141 { 142 *b = c; ++b; 143 case 7: *b = c; ++b; 144 case 6: *b = c; ++b; 145 case 5: *b = c; ++b; 146 case 4: *b = c; ++b; 147 case 3: *b = c; ++b; 148 case 2: *b = c; ++b; 142 *b = c; ++b; BOOST_FALLTHROUGH; 143 case 7: *b = c; ++b; BOOST_FALLTHROUGH; 144 case 6: *b = c; ++b; BOOST_FALLTHROUGH; 145 case 5: *b = c; ++b; BOOST_FALLTHROUGH; 146 case 4: *b = c; ++b; BOOST_FALLTHROUGH; 147 case 3: *b = c; ++b; BOOST_FALLTHROUGH; 148 case 2: *b = c; ++b; BOOST_FALLTHROUGH; 149 149 case 1: *b = c; ++b; 150 150 } 151 151 } -
boost/xpressive/detail/dynamic/parse_charset.hpp
246 246 case token_charset_hyphen: 247 247 case token_charset_invert: 248 248 begin = iprev2; // un-get these tokens and fall through 249 BOOST_FALLTHROUGH; 249 250 case token_literal: 250 251 ch_next = *begin++; 251 252 BOOST_XPR_ENSURE_(ch_prev <= ch_next, error_range, "invalid charset range"); … … 264 265 chset.set_range(ch_prev, esc.ch_, rxtraits, icase); 265 266 continue; 266 267 } 267 case token_charset_end: // fall through 268 BOOST_FALLTHROUGH; 269 case token_charset_end: 268 270 default: // not a range. 269 271 begin = iprev; // backup to hyphen token 270 272 chset.set_char(ch_prev, rxtraits, icase); -
boost/xpressive/detail/dynamic/parser_traits.hpp
394 394 case BOOST_XPR_CHAR_(char_type, 'm'): this->flag_(!set, single_line); break; 395 395 case BOOST_XPR_CHAR_(char_type, 's'): this->flag_(!set, not_dot_newline); break; 396 396 case BOOST_XPR_CHAR_(char_type, 'x'): this->flag_(set, ignore_white_space); break; 397 case BOOST_XPR_CHAR_(char_type, ':'): ++begin; // fall-through397 case BOOST_XPR_CHAR_(char_type, ':'): ++begin; BOOST_FALLTHROUGH; 398 398 case BOOST_XPR_CHAR_(char_type, ')'): return token_no_mark; 399 case BOOST_XPR_CHAR_(char_type, '-'): if(false == (set = !set)) break; // else fall-through399 case BOOST_XPR_CHAR_(char_type, '-'): if(false == (set = !set)) break; BOOST_FALLTHROUGH; 400 400 default: BOOST_THROW_EXCEPTION(regex_error(error_paren, "unknown pattern modifier")); 401 401 } 402 402 while(BOOST_XPR_ENSURE_(++begin != end, error_paren, "incomplete extension")); -
boost/xpressive/match_results.hpp
1096 1096 case BOOST_XPR_CHAR_(char_type, ':'): 1097 1097 if(metacolon) 1098 1098 { 1099 BOOST_FALLTHROUGH; 1099 1100 case BOOST_XPR_CHAR_(char_type, ')'): 1100 1101 ++cur; 1101 1102 return out; 1102 1103 } 1103 // else fall-through1104 BOOST_FALLTHROUGH; 1104 1105 1105 1106 default: 1106 1107 *out++ = *cur++; -
boost/xpressive/regex_compiler.hpp
282 282 break; 283 283 case 2: 284 284 seq = detail::make_dynamic<BidiIter>(alternate_matcher()) | seq; 285 // fall-through285 BOOST_FALLTHROUGH; 286 286 default: 287 287 seq |= this->parse_sequence(tmp, end); 288 288 } … … 322 322 break; 323 323 324 324 case token_negative_lookahead: 325 negative = true; // fall-through 325 negative = true; 326 BOOST_FALLTHROUGH; 326 327 case token_positive_lookahead: 327 328 lookahead = true; 328 329 break; 329 330 330 331 case token_negative_lookbehind: 331 negative = true; // fall-through 332 negative = true; 333 BOOST_FALLTHROUGH; 332 334 case token_positive_lookbehind: 333 335 lookbehind = true; 334 336 break; … … 342 344 { 343 345 switch(this->traits_.get_token(begin, end)) 344 346 { 345 case token_group_end: return this->parse_atom(begin, end); 346 case token_escape: BOOST_XPR_ENSURE_(begin != end, error_escape, "incomplete escape sequence"); 347 case token_literal: ++begin; 348 default:; 347 case token_group_end: 348 return this->parse_atom(begin, end); 349 case token_escape: 350 BOOST_XPR_ENSURE_(begin != end, error_escape, "incomplete escape sequence"); 351 BOOST_FALLTHROUGH; 352 case token_literal: 353 ++begin; 354 break; 355 default: 356 break; 349 357 } 350 358 } 351 359 break; … … 688 696 { 689 697 switch(this->traits_.get_token(begin, end)) 690 698 { 691 case token_quote_meta_end: return string_type(old_begin, old_end); 692 case token_escape: BOOST_XPR_ENSURE_(begin != end, error_escape, "incomplete escape sequence"); 699 case token_quote_meta_end: 700 return string_type(old_begin, old_end); 701 case token_escape: 702 BOOST_XPR_ENSURE_(begin != end, error_escape, "incomplete escape sequence"); 703 BOOST_FALLTHROUGH; 693 704 case token_invalid_quantifier: 694 case token_literal: ++begin; 695 default:; 705 case token_literal: 706 ++begin; 707 BOOST_FALLTHROUGH; 708 default: 709 break; 696 710 } 697 711 } 698 712 return string_type(old_begin, begin); -
libs/config/doc/html/boost_config/boost_macro_reference.html
3 3 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII"> 4 4 <title>Boost Macro Reference</title> 5 5 <link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css"> 6 <meta name="generator" content="DocBook XSL Stylesheets V1.7 7.1">6 <meta name="generator" content="DocBook XSL Stylesheets V1.78.1"> 7 7 <link rel="home" href="../index.html" title="Boost.Config"> 8 8 <link rel="up" href="../index.html" title="Boost.Config"> 9 9 <link rel="prev" href="../index.html" title="Boost.Config"> … … 26 26 <div class="titlepage"><div><div><h2 class="title" style="clear: both"> 27 27 <a name="boost_config.boost_macro_reference"></a><a class="link" href="boost_macro_reference.html" title="Boost Macro Reference">Boost Macro Reference</a> 28 28 </h2></div></div></div> 29 <div class="toc"><dl >29 <div class="toc"><dl class="toc"> 30 30 <dt><span class="section"><a href="boost_macro_reference.html#boost_config.boost_macro_reference.macros_that_describe_c__03_defects">Macros 31 31 that describe C++03 defects</a></span></dt> 32 32 <dt><span class="section"><a href="boost_macro_reference.html#boost_config.boost_macro_reference.macros_that_describe_optional_features">Macros … … 3384 3384 <tr> 3385 3385 <td> 3386 3386 <p> 3387 <code class="computeroutput"><span class="identifier">BOOST_FALLTHROUGH</span></code> 3388 </p> 3389 </td> 3390 <td> 3391 <p> 3392 The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through 3393 between switch labels: 3394 </p> 3395 <pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">switch</span> <span class="special">(</span><span class="identifier">x</span><span class="special">)</span> <span class="special">{</span> 3396 <span class="keyword">case</span> <span class="number">40</span><span class="special">:</span> 3397 <span class="keyword">case</span> <span class="number">41</span><span class="special">:</span> 3398 <span class="keyword">if</span> <span class="special">(</span><span class="identifier">truth_is_out_there</span><span class="special">)</span> <span class="special">{</span> 3399 <span class="special">++</span><span class="identifier">x</span><span class="special">;</span> 3400 <span class="identifier">BOOST_FALLTHROUGH</span><span class="special">;</span> <span class="comment">// Use instead of/along with annotations in</span> 3401 <span class="comment">// comments.</span> 3402 <span class="special">}</span> <span class="keyword">else</span> <span class="special">{</span> 3403 <span class="keyword">return</span> <span class="identifier">x</span><span class="special">;</span> 3404 <span class="special">}</span> 3405 <span class="keyword">case</span> <span class="number">42</span><span class="special">:</span> 3406 <span class="special">...</span> 3407 </pre> 3408 <p> 3409 As shown in the example above, the BOOST_FALLTHROUGH macro should 3410 be followed by a semicolon. It is designed to mimic control-flow 3411 statements like 'break;', so it can be placed in most places where 3412 'break;' can, but only if there are no statements on the execution 3413 path between it and the next switch label. 3414 </p> 3415 <p> 3416 When compiled with Clang >3.2 in C++11 mode, the BOOST_FALLTHROUGH 3417 macro is expanded to <code class="computeroutput"><span class="special">[[</span><span class="identifier">clang</span><span class="special">::</span><span class="identifier">fallthrough</span><span class="special">]]</span></code> 3418 attribute, which is analysed when performing switch labels fall-through 3419 diagnostic ('-Wimplicit-fallthrough'). See clang documentation 3420 on language extensions for details: http://clang.llvm.org/docs/LanguageExtensions.html#clang__fallthrough 3421 </p> 3422 <p> 3423 When used with unsupported compilers, the BOOST_FALLTHROUGH macro 3424 has no effect on diagnostics. 3425 </p> 3426 <p> 3427 In either case this macro has no effect on runtime behavior and 3428 performance of code. 3429 </p> 3430 </td> 3431 </tr> 3432 <tr> 3433 <td> 3434 <p> 3387 3435 <code class="computeroutput"><span class="identifier">BOOST_EXPLICIT_TEMPLATE_TYPE</span><span class="special">(</span><span class="identifier">t</span><span class="special">)</span></code> <code class="computeroutput"><span class="identifier">BOOST_EXPLICIT_TEMPLATE_NON_TYPE</span><span class="special">(</span><span class="identifier">t</span><span class="special">,</span><span class="identifier">v</span><span class="special">)</span></code> <code class="computeroutput"><span class="identifier">BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE</span><span class="special">(</span><span class="identifier">t</span><span class="special">)</span></code> <code class="computeroutput"><span class="identifier">BOOST_APPEND_EXPLICIT_TEMPLATE_NON_TYPE</span><span class="special">(</span><span class="identifier">t</span><span class="special">,</span><span class="identifier">v</span><span class="special">)</span></code> 3388 3436 </p> 3389 3437 </td> … … 4923 4971 <a name="boost_config.boost_macro_reference.macros_for_libraries_with_separate_source_code"></a><a class="link" href="boost_macro_reference.html#boost_config.boost_macro_reference.macros_for_libraries_with_separate_source_code" title="Macros for libraries with separate source code">Macros 4924 4972 for libraries with separate source code</a> 4925 4973 </h3></div></div></div> 4926 <div class="toc"><dl >4974 <div class="toc"><dl class="toc"> 4927 4975 <dt><span class="section"><a href="boost_macro_reference.html#boost_config.boost_macro_reference.macros_for_libraries_with_separate_source_code.macros_controlling_shared_library_symbol_visibility">Macros 4928 4976 controlling shared library symbol visibility</a></span></dt> 4929 4977 <dt><span class="section"><a href="boost_macro_reference.html#boost_config.boost_macro_reference.macros_for_libraries_with_separate_source_code.abi_fixing">ABI -
libs/config/doc/macro_reference.qbk
862 862 Normally evaluates to nothing, but evaluates to return x; if the compiler 863 863 requires a return, even when it can never be reached. 864 864 ]] 865 [[`BOOST_FALLTHROUGH`][ 866 The BOOST_FALLTHROUGH macro can be used to annotate implicit fall-through 867 between switch labels: 868 `` 869 switch (x) { 870 case 40: 871 case 41: 872 if (truth_is_out_there) { 873 ++x; 874 BOOST_FALLTHROUGH; // Use instead of/along with annotations in 875 // comments. 876 } else { 877 return x; 878 } 879 case 42: 880 ... 881 `` 882 As shown in the example above, the BOOST_FALLTHROUGH macro should be 883 followed by a semicolon. It is designed to mimic control-flow statements 884 like 'break;', so it can be placed in most places where 'break;' can, but 885 only if there are no statements on the execution path between it and the 886 next switch label. 887 888 When compiled with Clang >3.2 in C++11 mode, the BOOST_FALLTHROUGH macro is 889 expanded to `[[clang::fallthrough]]` attribute, which is analysed when 890 performing switch labels fall-through diagnostic ('-Wimplicit-fallthrough'). 891 See clang documentation on language extensions for details: 892 http://clang.llvm.org/docs/LanguageExtensions.html#clang__fallthrough 893 894 When used with unsupported compilers, the BOOST_FALLTHROUGH macro has no 895 effect on diagnostics. 896 897 In either case this macro has no effect on runtime behavior and performance 898 of code. 899 ]] 865 900 [[`BOOST_EXPLICIT_TEMPLATE_TYPE(t)` 866 901 `BOOST_EXPLICIT_TEMPLATE_NON_TYPE(t,v)` 867 902 `BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE(t)` -
libs/config/test/boost_no_std_wstreambuf.ipp
61 61 case ::std::ios_base::beg: 62 62 if((off < 0) || (off > size)) 63 63 return pos_type(off_type(-1)); 64 else65 this->setg(g, g + off, g + size);64 this->setg(g, g + off, g + size); 65 BOOST_FALLTHROUGH; 66 66 case ::std::ios_base::end: 67 67 if((off < 0) || (off > size)) 68 68 return pos_type(off_type(-1)); 69 else70 this->setg(g, g + size - off, g + size);69 this->setg(g, g + size - off, g + size); 70 BOOST_FALLTHROUGH; 71 71 case ::std::ios_base::cur: 72 72 { 73 73 int newpos = pos + off; -
libs/graph/src/read_graphviz_new.cpp
230 230 case '>': return token(token::dash_greater, str); 231 231 default: BOOST_ASSERT (!"Definition of punctuation_token does not match switch statement"); 232 232 } 233 break; 233 234 } 234 235 default: BOOST_ASSERT (!"Definition of punctuation_token does not match switch statement"); 235 236 } … … 604 605 } 605 606 default: error("Wanted identifier or left parenthesis as start of port location"); 606 607 } 608 break; 607 609 } 608 610 default: break; 609 611 } -
libs/locale/src/util/gregorian.cpp
207 207 value += (-value / 7) * 7 + 7; 208 208 // convert to local DOW 209 209 value = (value - 1 - first_day_of_week_ + 14) % 7 + 1; 210 // fall throght210 BOOST_FALLTHROUGH; 211 211 case day_of_week_local: ///< Local day of week, for example in France Monday is 1, in US Sunday is 1, [1..7] 212 212 normalize(); 213 213 tm_updated_.tm_mday += (value - 1) - (tm_updated_.tm_wday - first_day_of_week_ + 7) % 7; … … 666 666 normalize(); 667 667 } 668 668 } 669 break; 669 670 default: 670 ;671 break; 671 672 } 672 673 } 673 674 … … 726 727 case week_of_month: 727 728 case week_of_year: 728 729 factor = 7; 729 // fall730 BOOST_FALLTHROUGH; 730 731 case day: 731 732 case day_of_year: 732 733 case day_of_week: -
libs/locale/test/test_locale.hpp
81 81 switch(l) { 82 82 case 3: 83 83 c = (c << 6) | (((unsigned char)s[pos++]) & 0x3F); 84 BOOST_FALLTHROUGH; 84 85 case 2: 85 86 c = (c << 6) | (((unsigned char)s[pos++]) & 0x3F); 87 BOOST_FALLTHROUGH; 86 88 case 1: 87 89 c = (c << 6) | (((unsigned char)s[pos++]) & 0x3F); 88 90 } -
libs/serialization/test/B.hpp
67 67 ar >> BOOST_SERIALIZATION_NVP(v); 68 68 ar >> BOOST_SERIALIZATION_NVP(w); 69 69 ar >> BOOST_SERIALIZATION_NVP(x); 70 break; 70 71 default: 71 72 break; 72 73 } -
libs/wave/samples/cpp_tokens/slex/cpp_slex_lexer.hpp
658 658 case T_EXTSTRINGLIT: 659 659 case T_EXTRAWSTRINGLIT: 660 660 id = token_id(id & ~AltTokenType); 661 // fall through661 BOOST_FALLTHROUGH; 662 662 663 663 case T_CHARLIT: 664 664 case T_STRINGLIT: -
tools/quickbook/src/actions.cpp
1101 1101 case '\n': 1102 1102 case '\r': 1103 1103 if (depth == 0) return begin; 1104 break; 1104 1105 default: 1105 1106 break; 1106 1107 }