diff -Naur gcc-4.9.3-orig/gcc/cp/cfns.gperf gcc-4.9.3-fixed/gcc/cp/cfns.gperf
old
|
new
|
|
| 1 | %language=C++ |
| 2 | %define class-name libc_name |
1 | 3 | %{ |
2 | 4 | /* Copyright (C) 2000-2014 Free Software Foundation, Inc. |
3 | 5 | |
… |
… |
|
16 | 18 | You should have received a copy of the GNU General Public License |
17 | 19 | along with GCC; see the file COPYING3. If not see |
18 | 20 | <http://www.gnu.org/licenses/>. */ |
19 | | #ifdef __GNUC__ |
20 | | __inline |
21 | | #endif |
22 | | static unsigned int hash (const char *, unsigned int); |
23 | | #ifdef __GNUC__ |
24 | | __inline |
25 | | #endif |
26 | | const char * libc_name_p (const char *, unsigned int); |
27 | 21 | %} |
28 | 22 | %% |
29 | 23 | # The standard C library functions, for feeding to gperf; the result is used |
diff -Naur gcc-4.9.3-orig/gcc/cp/cfns.h gcc-4.9.3-fixed/gcc/cp/cfns.h
old
|
new
|
|
1 | | /* ANSI-C code produced by gperf version 3.0.3 */ |
2 | | /* Command-line: gperf -o -C -E -k '1-6,$' -j1 -D -N libc_name_p -L ANSI-C cfns.gperf */ |
| 1 | /* C++ code produced by gperf version 3.0.4 */ |
| 2 | /* Command-line: gperf -o -C -E -k '1-6,$' -j1 -D -N libc_name_p -L C++ --output-file cfns.h cfns.gperf */ |
3 | 3 | |
4 | 4 | #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ |
5 | 5 | && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ |
… |
… |
|
28 | 28 | #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>." |
29 | 29 | #endif |
30 | 30 | |
31 | | #line 1 "cfns.gperf" |
| 31 | #line 3 "cfns.gperf" |
32 | 32 | |
33 | 33 | /* Copyright (C) 2000-2014 Free Software Foundation, Inc. |
34 | 34 | |
… |
… |
|
47 | 47 | You should have received a copy of the GNU General Public License |
48 | 48 | along with GCC; see the file COPYING3. If not see |
49 | 49 | <http://www.gnu.org/licenses/>. */ |
50 | | #ifdef __GNUC__ |
51 | | __inline |
52 | | #endif |
53 | | static unsigned int hash (const char *, unsigned int); |
54 | | #ifdef __GNUC__ |
55 | | __inline |
56 | | #endif |
57 | | const char * libc_name_p (const char *, unsigned int); |
58 | 50 | /* maximum key range = 391, duplicates = 0 */ |
59 | 51 | |
60 | | #ifdef __GNUC__ |
61 | | __inline |
62 | | #else |
63 | | #ifdef __cplusplus |
64 | | inline |
65 | | #endif |
66 | | #endif |
67 | | static unsigned int |
68 | | hash (register const char *str, register unsigned int len) |
| 52 | class libc_name |
| 53 | { |
| 54 | private: |
| 55 | static inline unsigned int hash (const char *str, unsigned int len); |
| 56 | public: |
| 57 | static const char *libc_name_p (const char *str, unsigned int len); |
| 58 | }; |
| 59 | |
| 60 | inline unsigned int |
| 61 | libc_name::hash (register const char *str, register unsigned int len) |
69 | 62 | { |
70 | 63 | static const unsigned short asso_values[] = |
71 | 64 | { |
… |
… |
|
122 | 115 | return hval + asso_values[(unsigned char)str[len - 1]]; |
123 | 116 | } |
124 | 117 | |
125 | | #ifdef __GNUC__ |
126 | | __inline |
127 | | #ifdef __GNUC_STDC_INLINE__ |
128 | | __attribute__ ((__gnu_inline__)) |
129 | | #endif |
130 | | #endif |
131 | 118 | const char * |
132 | | libc_name_p (register const char *str, register unsigned int len) |
| 119 | libc_name::libc_name_p (register const char *str, register unsigned int len) |
133 | 120 | { |
134 | 121 | enum |
135 | 122 | { |
diff -Naur gcc-4.9.3-orig/gcc/cp/except.c gcc-4.9.3-fixed/gcc/cp/except.c
old
|
new
|
|
1030 | 1030 | unless the system headers are playing rename tricks, and if |
1031 | 1031 | they are, we don't want to be confused by them. */ |
1032 | 1032 | id = DECL_NAME (fn); |
1033 | | return !!libc_name_p (IDENTIFIER_POINTER (id), IDENTIFIER_LENGTH (id)); |
| 1033 | return !!libc_name::libc_name_p (IDENTIFIER_POINTER (id), |
| 1034 | IDENTIFIER_LENGTH (id)); |
1034 | 1035 | } |
1035 | 1036 | |
1036 | 1037 | /* Returns nonzero if an exception of type FROM will be caught by a |
diff -Naur gcc-4.9.3-orig/gcc/cp/Make-lang.in gcc-4.9.3-fixed/gcc/cp/Make-lang.in
old
|
new
|
|
111 | 111 | # deleting the $(srcdir)/cp/cfns.h file. |
112 | 112 | $(srcdir)/cp/cfns.h: |
113 | 113 | endif |
114 | | gperf -o -C -E -k '1-6,$$' -j1 -D -N 'libc_name_p' -L ANSI-C \ |
| 114 | gperf -o -C -E -k '1-6,$$' -j1 -D -N 'libc_name_p' -L C++ \ |
115 | 115 | $(srcdir)/cp/cfns.gperf --output-file $(srcdir)/cp/cfns.h |
116 | 116 | |
117 | 117 | # |