Author: hhinnant
Date: Thu Oct 14 12:11:39 2010
New Revision: 116487

URL: http://llvm.org/viewvc/llvm-project?rev=116487&view=rev
Log:
Bug 7983 fixed by Bernhard Rosenkraenzer

Modified:
    libcxx/trunk/include/cstring

Modified: libcxx/trunk/include/cstring
URL: 
http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/cstring?rev=116487&r1=116486&r2=116487&view=diff
==============================================================================
--- libcxx/trunk/include/cstring (original)
+++ libcxx/trunk/include/cstring Thu Oct 14 12:11:39 2010
@@ -78,23 +78,26 @@
 using ::strxfrm;
 
 using ::memchr;
-inline _LIBCPP_INLINE_VISIBILITY       void* memchr(      void* __s, int __c, 
size_t __n) {return ::memchr(__s, __c, __n);}
 
 using ::strchr;
-inline _LIBCPP_INLINE_VISIBILITY       char* strchr(      char* __s, int __c) 
{return ::strchr(__s, __c);}
 
 using ::strcspn;
 
 using ::strpbrk;
-inline _LIBCPP_INLINE_VISIBILITY       char* strpbrk(      char* __s1, const 
char* __s2) {return ::strpbrk(__s1, __s2);}
 
 using ::strrchr;
-inline _LIBCPP_INLINE_VISIBILITY       char* strrchr(      char* __s, int __c) 
{return ::strrchr(__s, __c);}
 
 using ::strspn;
 
 using ::strstr;
+
+#ifndef __GLIBC__ // GNU libc and its derivates already have the correct 
prototype in <string.h> #ifdef __cplusplus
+inline _LIBCPP_INLINE_VISIBILITY       char* strchr(      char* __s, int __c) 
{return ::strchr(__s, __c);}
+inline _LIBCPP_INLINE_VISIBILITY       char* strpbrk(      char* __s1, const 
char* __s2) {return ::strpbrk(__s1, __s2);}
+inline _LIBCPP_INLINE_VISIBILITY       char* strrchr(      char* __s, int __c) 
{return ::strrchr(__s, __c);}
+inline _LIBCPP_INLINE_VISIBILITY       void* memchr(      void* __s, int __c, 
size_t __n) {return ::memchr(__s, __c, __n);}
 inline _LIBCPP_INLINE_VISIBILITY       char* strstr(      char* __s1, const 
char* __s2) {return ::strstr(__s1, __s2);}
+#endif
 
 using ::strtok;
 using ::memset;


_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to