diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2018-12-07 12:04:53 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2018-12-08 15:40:59 +0100 |
commit | a061abd3949f933e93c84f9f67f0700055a054f7 (patch) | |
tree | e45371dab6f6bf14c82ce40dff836176aad48aa8 /configure.ac | |
parent | 5f8b6b09871ba1f1bd2b6f0aa9d1a9ce931fdc19 (diff) |
HAVE_CPP_ATTRIBUTE_NODISCARD is always true now
...but for safety, leave the configure.ac check in for some longer.
Also, save removing now-redundant SAL_WARN_UNUSED_RESULT in internal code for a
follow-up commit.
Change-Id: Ibe30b51c5cc4abc270f955c7c40b59f268986672
Reviewed-on: https://gerrit.libreoffice.org/64771
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac index f05c84110f4f..1dc1b712302d 100644 --- a/configure.ac +++ b/configure.ac @@ -6447,7 +6447,8 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([[ CXXFLAGS=$save_CXXFLAGS AC_LANG_POP([C++]) -AC_MSG_CHECKING([[whether $CXX supports [[nodiscard]]]]) +dnl This check can eventually be removed completely (e.g., after libreoffice-6-3 branch off): +AC_MSG_CHECKING([[that $CXX supports [[nodiscard]]]]) AC_LANG_PUSH([C++]) save_CXXFLAGS=$CXXFLAGS CXXFLAGS="$CXXFLAGS $CXXFLAGS_CXX11" @@ -6467,10 +6468,8 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([[ #else [[nodiscard]] int f(); #endif - ]])], [ - AC_DEFINE([HAVE_CPP_ATTRIBUTE_NODISCARD],[1]) - AC_MSG_RESULT([yes]) - ], [AC_MSG_RESULT([no])]) + ]])], + AC_MSG_RESULT([yes]), AC_MSG_ERROR([$CXX lacks required [[nodiscard]] support])) CXXFLAGS=$save_CXXFLAGS AC_LANG_POP([C++]) |