From 03be83f5a444183083f895352133f04b24fcc48f Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Mon, 2 Mar 2015 17:31:55 +0100 Subject: use g_assert_not_reached() instead of g_assert(false): works around Clang++ warnings * Clang++ does not see that the PC will never go beyong g_assert(false), and so reports about possible unitialized variables --- src/expressions.cpp | 2 +- src/search.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/expressions.cpp b/src/expressions.cpp index f397b13..fc1e5e2 100644 --- a/src/expressions.cpp +++ b/src/expressions.cpp @@ -178,7 +178,7 @@ Expressions::calc(void) break; default: /* shouldn't happen */ - g_assert(false); + g_assert_not_reached(); } push(result); diff --git a/src/search.cpp b/src/search.cpp index 9519fb9..370dbfc 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -334,7 +334,7 @@ StateSearch::pattern2regexp(const gchar *&pattern, default: /* shouldn't happen */ - g_assert(false); + g_assert_not_reached(); } next: -- cgit v1.2.3