diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2021-02-11 07:52:26 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-02-11 08:45:01 +0100 |
commit | f59dd9c2d928432ae2ebc311cdfe65dc74f3db33 (patch) | |
tree | aa052cf32f3b3d343a201617c9af1d9e34689b12 /unoidl/source | |
parent | 1eb05baf7cffe5ad747f6ab5ba65e07c7a9dcf80 (diff) |
Silence some -Wimplicit-fallthrough
("fallthrough annotation in unreachable code")
Change-Id: I707451cf7f5215e228763049b9903240de1987cb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110747
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'unoidl/source')
-rw-r--r-- | unoidl/source/sourceprovider-parser.y | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/unoidl/source/sourceprovider-parser.y b/unoidl/source/sourceprovider-parser.y index 565ac9d8dec9..9d1dd5ae49d0 100644 --- a/unoidl/source/sourceprovider-parser.y +++ b/unoidl/source/sourceprovider-parser.y @@ -16,6 +16,7 @@ #include <sal/config.h> +#include <o3tl/unreachable.hxx> #include <rtl/ustrbuf.hxx> #include <unoidl/unoidl.hxx> @@ -1923,8 +1924,7 @@ typedefDefn: case unoidl::detail::SourceProviderEntity::KIND_PUBLISHED_INTERFACE_DECL: break; case unoidl::detail::SourceProviderEntity::KIND_MODULE: - assert(false && "this cannot happen"); - [[fallthrough]]; + O3TL_UNREACHABLE; default: assert(t.entity->entity.is() || t.entity->pad.is()); unpub @@ -1943,8 +1943,7 @@ typedefDefn: } break; case unoidl::detail::SourceProviderType::TYPE_PARAMETER: - assert(false && "this cannot happen"); - [[fallthrough]]; + O3TL_UNREACHABLE; default: break; } @@ -3855,8 +3854,7 @@ type: ok = true; break; case unoidl::Entity::SORT_TYPEDEF: - assert(false && "this cannot happen"); - [[fallthrough]]; + O3TL_UNREACHABLE; default: break; } @@ -4441,8 +4439,7 @@ bool parse(OUString const & uri, SourceProviderScannerData * data) { case 0: break; default: - assert(false); - [[fallthrough]]; + O3TL_UNREACHABLE; case 1: throw FileFormatException( uri, |