Ian Lance Taylor <i...@google.com> writes:

> Suppose you drop this into include/libiberty.h:
>
> #ifdef __cplusplus
> inline char *lbasename(char *s) { return const_cast<char*>(lbasename (s)); }
> #endif

That doesn't work:

../../gcc/libcpp/../include/libiberty.h: In function ‘char* lbasename(char*)’:
../../gcc/libcpp/../include/libiberty.h:123:31: error: declaration of C 
function ‘char* lbasename(char*)’ conflicts with
../../gcc/libcpp/../include/libiberty.h:121:20: error: previous declaration 
‘const char* lbasename(const char*)’ here

Andreas.

-- 
Andreas Schwab, sch...@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

Reply via email to