From: Paul Eggert Date: Mon, 20 May 2024 16:08:27 +0000 (-0700) Subject: * m4/byteswap.m4: Add comment about broken C libraries. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=6dbbada2b05bdc5efd0a5592a7805c92fe0531c6;p=gnulib.git * m4/byteswap.m4: Add comment about broken C libraries. --- diff --git a/m4/byteswap.m4 b/m4/byteswap.m4 index 3f5ef45cfe..3185bab763 100644 --- a/m4/byteswap.m4 +++ b/m4/byteswap.m4 @@ -15,6 +15,10 @@ AC_DEFUN([gl_BYTESWAP], AC_CACHE_CHECK([for working bswap_16, bswap_32, bswap_64], [gl_cv_header_working_byteswap_h], [gl_cv_header_working_byteswap_h=no + dnl Check that floating point arguments work. + dnl This also checks C libraries with implementations like + dnl '#define bswap_16(x) (((x) >> 8 & 0xff) | (((x) & 0xff) << 8))' + dnl that mistakenly evaluate their arguments multiple times. AC_COMPILE_IFELSE( [AC_LANG_PROGRAM( [[#include