this is unrelated to GCC, but is seen with glibc-2.10; see a diff of the preprocessed file (built with libc6-dev 2.9, vs built with 2.10.1)
-extern char *strchr (__const char *__s, int __c) - throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
-extern char *strrchr (__const char *__s, int __c) - throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); +extern "C++" +{ +extern char *strchr (char *__s, int __c) + throw () __asm ("strchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); +extern __const char *strchr (__const char *__s, int __c) + throw () __asm ("strchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); + + +extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__, __artificial__)) char * +strchr (char *__s, int __c) throw () +{ + return __builtin_strchr (__s, __c); +}
+extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__, __artificial__)) __const char * +strchr (__const char *__s, int __c) throw () +{ + return __builtin_strchr (__s, __c); +}
this is unrelated to GCC, but is seen with glibc-2.10; see a diff of the preprocessed file (built with libc6-dev 2.9, vs built with 2.10.1)
-extern char *strchr (__const char *__s, int __c)
- throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
-extern char *strrchr (__const char *__s, int __c) inline_ _)) __attribute__ ((__gnu_inline__, __artificial__)) char *
- throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
+extern "C++"
+{
+extern char *strchr (char *__s, int __c)
+ throw () __asm ("strchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
+extern __const char *strchr (__const char *__s, int __c)
+ throw () __asm ("strchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
+
+
+extern __inline __attribute__ ((__always_
+strchr (char *__s, int __c) throw ()
+{
+ return __builtin_strchr (__s, __c);
+}
+extern __inline __attribute__ ((__always_ inline_ _)) __attribute__ ((__gnu_inline__, __artificial__)) __const char *
+strchr (__const char *__s, int __c) throw ()
+{
+ return __builtin_strchr (__s, __c);
+}