maint: remove unneeded suggest-attributes pragmas

* gl/lib/fadvise.c: Remove pragma that works around GCC bug 83559
<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=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.
This commit is contained in:
Paul Eggert 2024-02-17 21:36:37 -08:00
parent d39c523728
commit aed1aa29db
2 changed files with 0 additions and 12 deletions

View File

@ -14,12 +14,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>. */
/* 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 <config.h>
#include "fadvise.h"

View File

@ -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 <config.h>
#include <ctype.h>
#include <stdio.h>