diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2019-12-09 15:13:59 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2019-12-09 16:25:00 +0100 |
commit | 9631f5d35d1870faf4ca2a19fe30b827a1f59905 (patch) | |
tree | 125631ad126656e5f506bda07cd972f6dc3b3d40 /libreofficekit | |
parent | 919375354c769ac9cc6a49ebfbfb84aa0f15df39 (diff) |
Prefer O3TL_UNREACHABLE over assert(false)
...so that -Werror=maybe-uninitialized is also silenced (cf.
281f3d5c418e50a2858619633ebca290bd626c03 "Silence -Werror=maybe-uninitialized")
with --disable-assert-always-abort
Change-Id: Ie31e18d27823b061375a0740b85bec95740bbecd
Reviewed-on: https://gerrit.libreoffice.org/84752
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'libreofficekit')
-rw-r--r-- | libreofficekit/qa/gtktiledviewer/gtv-calc-header-bar.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libreofficekit/qa/gtktiledviewer/gtv-calc-header-bar.cxx b/libreofficekit/qa/gtktiledviewer/gtv-calc-header-bar.cxx index 10b9de01d9a0..43037b5059f5 100644 --- a/libreofficekit/qa/gtktiledviewer/gtv-calc-header-bar.cxx +++ b/libreofficekit/qa/gtktiledviewer/gtv-calc-header-bar.cxx @@ -9,7 +9,6 @@ #include <gtk/gtk.h> -#include <cassert> #include <cmath> #include <iostream> @@ -21,6 +20,7 @@ #include <map> #include <boost/property_tree/json_parser.hpp> #include <o3tl/optional.hxx> +#include <o3tl/unreachable.hxx> namespace { @@ -150,7 +150,7 @@ static bool gtv_calc_header_bar_draw_impl(GtkWidget* pWidget, cairo_t* pCairo) } else { - assert(false); // should never happen + O3TL_UNREACHABLE; // should never happen } gtv_calc_header_bar_draw_text(pCairo, aRectangle, rHeader.m_aText); |