Module Name: src
Committed By: hgutch
Date: Wed Apr 24 16:48:30 UTC 2024
Modified Files:
src/external/gpl3/gcc.old/dist/gcc/cp: cfns.h
Log Message:
Fix gcc build on FreeBSD 14 (and possibly other systems using clang >= 16).
Pointed out by Eirik Øverby.
OK mrg@
To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/external/gpl3/gcc.old/dist/gcc/cp/cfns.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/gpl3/gcc.old/dist/gcc/cp/cfns.h
diff -u src/external/gpl3/gcc.old/dist/gcc/cp/cfns.h:1.11 src/external/gpl3/gcc.old/dist/gcc/cp/cfns.h:1.12
--- src/external/gpl3/gcc.old/dist/gcc/cp/cfns.h:1.11 Mon Feb 20 02:11:23 2023
+++ src/external/gpl3/gcc.old/dist/gcc/cp/cfns.h Wed Apr 24 16:48:29 2024
@@ -60,7 +60,7 @@ public:
};
inline unsigned int
-libc_name::hash (register const char *str, register unsigned int len)
+libc_name::hash (const char *str, unsigned int len)
{
static const unsigned short asso_values[] =
{
@@ -91,7 +91,7 @@ libc_name::hash (register const char *st
1488, 1488, 1488, 1488, 1488, 1488, 1488, 1488, 1488, 1488,
1488, 1488, 1488, 1488, 1488, 1488, 1488
};
- register int hval = len;
+ int hval = len;
switch (hval)
{
@@ -118,7 +118,7 @@ libc_name::hash (register const char *st
}
const struct libc_name_struct *
-libc_name::libc_name_p (register const char *str, register unsigned int len)
+libc_name::libc_name_p (const char *str, unsigned int len)
{
enum
{
@@ -1116,15 +1116,15 @@ libc_name::libc_name_p (register const c
if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH)
{
- register int key = hash (str, len);
+ int key = hash (str, len);
if (key <= MAX_HASH_VALUE && key >= 0)
{
- register int index = lookup[key];
+ int index = lookup[key];
if (index >= 0)
{
- register const char *s = wordlist[index].name;
+ const char *s = wordlist[index].name;
if (*str == *s && !strcmp (str + 1, s + 1))
return &wordlist[index];