From: Paul Eggert Date: Sun, 18 Feb 2024 05:36:37 +0000 (-0800) Subject: maint: remove unneeded suggest-attributes pragmas X-Git-Tag: v9.5~68 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aed1aa29db176dc1bdf03805fe04ae87ffc152d9;p=thirdparty%2Fcoreutils.git maint: remove unneeded suggest-attributes pragmas * gl/lib/fadvise.c: Remove pragma that works around GCC bug 83559 . This bug was fixed in GCC 9, and we needn’t worry about --enable-gcc-warnings for compilers that old. * src/test.c: Likewise. --- diff --git a/gl/lib/fadvise.c b/gl/lib/fadvise.c index 4bbd3059e8..ed5b7ae328 100644 --- a/gl/lib/fadvise.c +++ b/gl/lib/fadvise.c @@ -14,12 +14,6 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -/* Without this pragma, gcc suggests that (given !HAVE_POSIX_FADVISE) - the fdadvise function might be a candidate for attribute 'const'. */ -#if (__GNUC__ == 4 && 6 <= __GNUC_MINOR__) || 4 < __GNUC__ -# pragma GCC diagnostic ignored "-Wsuggest-attribute=const" -#endif - #include #include "fadvise.h" diff --git a/src/test.c b/src/test.c index 09804cf38d..2da04d4c5a 100644 --- a/src/test.c +++ b/src/test.c @@ -20,12 +20,6 @@ /* Define TEST_STANDALONE to get the /bin/test version. Otherwise, you get the shell builtin version. */ -/* Without this pragma, gcc 4.6.2 20111027 mistakenly suggests that - the advance function might be candidate for attribute 'pure'. */ -#if (__GNUC__ == 4 && 6 <= __GNUC_MINOR__) || 4 < __GNUC__ -# pragma GCC diagnostic ignored "-Wsuggest-attribute=pure" -#endif - #include #include #include