[libcxx-commits] [libcxx] [libcxx] [regex] add `[[clang::fallthrough]]` to suppress fallthrough warning (PR #100821)
Nikolas Klauser via libcxx-commits
libcxx-commits at lists.llvm.org
Sat Jul 27 01:03:22 PDT 2024
================
@@ -3921,7 +3921,7 @@ _ForwardIterator basic_regex<_CharT, _Traits>::__parse_character_escape(
if (__hd == -1)
__throw_regex_error<regex_constants::error_escape>();
__sum = 16 * __sum + static_cast<unsigned>(__hd);
- // fallthrough
+ [[clang::fallthrough]];
----------------
philnik777 wrote:
Given that there was a `fallthrough` comment, I'd assume it was intentional. And, as @frederick-vs-ja we should make this `[[__fallthrough__]]` instead.
https://github.com/llvm/llvm-project/pull/100821
More information about the libcxx-commits
mailing list