1 Upstream commit r233720
3 diff --git a/gcc/cp/cfns.gperf b/gcc/cp/cfns.gperf
4 index 68acd3d..214ecf6 100644
5 --- a/gcc/cp/cfns.gperf
6 +++ b/gcc/cp/cfns.gperf
9 +%define class-name libc_name
11 /* Copyright (C) 2000-2015 Free Software Foundation, Inc.
13 @@ -16,14 +18,6 @@ for more details.
14 You should have received a copy of the GNU General Public License
15 along with GCC; see the file COPYING3. If not see
16 <http://www.gnu.org/licenses/>. */
20 -static unsigned int hash (const char *, unsigned int);
24 -const char * libc_name_p (const char *, unsigned int);
27 # The standard C library functions, for feeding to gperf; the result is used
28 diff --git a/gcc/cp/cfns.h b/gcc/cp/cfns.h
29 index 1c6665d..596f413 100644
33 -/* ANSI-C code produced by gperf version 3.0.3 */
34 -/* Command-line: gperf -o -C -E -k '1-6,$' -j1 -D -N libc_name_p -L ANSI-C cfns.gperf */
35 +/* C++ code produced by gperf version 3.0.4 */
36 +/* Command-line: gperf -o -C -E -k '1-6,$' -j1 -D -N libc_name_p -L C++ --output-file cfns.h cfns.gperf */
38 #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \
39 && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \
41 #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>."
47 /* Copyright (C) 2000-2015 Free Software Foundation, Inc.
49 @@ -47,25 +47,18 @@ for more details.
50 You should have received a copy of the GNU General Public License
51 along with GCC; see the file COPYING3. If not see
52 <http://www.gnu.org/licenses/>. */
56 -static unsigned int hash (const char *, unsigned int);
60 -const char * libc_name_p (const char *, unsigned int);
61 /* maximum key range = 391, duplicates = 0 */
71 -hash (register const char *str, register unsigned int len)
75 + static inline unsigned int hash (const char *str, unsigned int len);
77 + static const char *libc_name_p (const char *str, unsigned int len);
81 +libc_name::hash (register const char *str, register unsigned int len)
83 static const unsigned short asso_values[] =
85 @@ -122,14 +115,8 @@ hash (register const char *str, register unsigned int len)
86 return hval + asso_values[(unsigned char)str[len - 1]];
91 -#ifdef __GNUC_STDC_INLINE__
92 -__attribute__ ((__gnu_inline__))
96 -libc_name_p (register const char *str, register unsigned int len)
97 +libc_name::libc_name_p (register const char *str, register unsigned int len)
101 diff --git a/gcc/cp/except.c b/gcc/cp/except.c
102 index 3ff1ce6..2f2e396 100644
103 --- a/gcc/cp/except.c
104 +++ b/gcc/cp/except.c
105 @@ -1040,7 +1040,8 @@ nothrow_libfn_p (const_tree fn)
106 unless the system headers are playing rename tricks, and if
107 they are, we don't want to be confused by them. */
109 - return !!libc_name_p (IDENTIFIER_POINTER (id), IDENTIFIER_LENGTH (id));
110 + return !!libc_name::libc_name_p (IDENTIFIER_POINTER (id),
111 + IDENTIFIER_LENGTH (id));
114 /* Returns nonzero if an exception of type FROM will be caught by a