diff options
author | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2012-04-25 12:48:17 +0000 |
---|---|---|
committer | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2012-04-25 12:48:17 +0000 |
commit | 68e38b64b657b9b450c700bebde98075566e4bdd (patch) | |
tree | 7a0561f10b980eea014137db8feb260835bcba9b /acinclude.m4 | |
parent | e16ac7e15dd48f1dd7f3b8ff98f5eaf12f0a7982 (diff) | |
download | mpfr-68e38b64b657b9b450c700bebde98075566e4bdd.tar.gz |
Added support for _Noreturn function specifier (ISO C11).
* acinclude.m4: define MPFR_HAVE_NORETURN if _Noreturn is supported.
* src/mpfr-impl.h: use _Noreturn when MPFR_HAVE_NORETURN is defined.
Tested with GCC 4.6 (no _Noreturn) and 4.7 (supports _Noreturn).
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@8156 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'acinclude.m4')
-rw-r--r-- | acinclude.m4 | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/acinclude.m4 b/acinclude.m4 index cfe5e283a..6109d3750 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -137,6 +137,15 @@ AC_CHECK_TYPE( [union fpc_csr], #endif ]) +dnl Check for _Noreturn function specifier (ISO C11) +AC_CACHE_CHECK([for _Noreturn], mpfr_cv_have_noreturn, [ + AC_COMPILE_IFELSE([AC_LANG_SOURCE([[_Noreturn void foo(int);]])], + mpfr_cv_have_noreturn=yes, mpfr_cv_have_noreturn=no) +]) +if test "$mpfr_cv_have_noreturn" = "yes"; then + AC_DEFINE(MPFR_HAVE_NORETURN,1,[Define if the _Noreturn function specifier is supported.]) +fi + dnl Check for fesetround AC_CACHE_CHECK([for fesetround], mpfr_cv_have_fesetround, [ saved_LIBS="$LIBS" |