include/o3tl/unreachable.hxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 8597748c42727b62e60f8a4af45520193d682de0
Author:     Stephan Bergmann <sberg...@redhat.com>
AuthorDate: Mon Feb 28 21:14:11 2022 +0100
Commit:     Stephan Bergmann <sberg...@redhat.com>
CommitDate: Mon Feb 28 22:54:38 2022 +0100

    Brown paper bag fix
    
    ...of 87369ad7b82da6904e889614c88617e610d4506b "Use std::unreachable if
    available".  (Unfortunately, Clang didn't warn about the thus meaningless 
uses
    of O3TL_UNREACHABLE, presumably due to
    
<https://github.com/llvm/llvm-project/commit/978cca9f49a1c0e3a01096017c9a34726866fbf3>
    "Suppress all -Wunused-value warnings from macro body expansions.")
    
    (While at it, and as the expansion of O3TL_UNREACHABLE is now a nice full
    expression, wrap it in parentheses, as is common best practice for such 
macro
    definitions.)
    
    Change-Id: I555e6716ebb66172add686521446d90db6054845
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130729
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sberg...@redhat.com>

diff --git a/include/o3tl/unreachable.hxx b/include/o3tl/unreachable.hxx
index d5a2e156b760..604f7a2f7728 100644
--- a/include/o3tl/unreachable.hxx
+++ b/include/o3tl/unreachable.hxx
@@ -21,7 +21,7 @@
 
 #if defined __cpp_lib_unreachable
 
-#define O3TL_UNREACHABLE ::std::unreachable
+#define O3TL_UNREACHABLE (::std::unreachable())
 
 #else
 

Reply via email to