This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/27340] valarray uses __cos which may conflict with libm functions
- From: "pcarlini at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Apr 2006 20:01:49 -0000
- Subject: [Bug libstdc++/27340] valarray uses __cos which may conflict with libm functions
- References: <bug-27340-6008@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #3 from pcarlini at suse dot de 2006-04-28 20:01 -------
(In reply to comment #2)
> (In reply to comment #1)
> > Both libc and libstdc++ are considered part of the implementation which means
> > both are valid to use this name space.
>
> Which means both should take care not to use a name (in this name space)
> already used by the other one. I actually don't understand what your point is.
Well, I think Andrew has a point: suppose we rename all those functions to
_M_cos and co. Then, later, we discover that a third libc (not Solaris, not
GNU) conflicts with those names too... The point is that there is no *robust*
concept of less-conflict prone name: if such conflicts happen then something is
wrong in the design, something profound is wrong, somewhere. We already
discussed this issue in another context (header guards names), and, not having
looked very closely into this specific issue, I'm pretty convinced.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27340