Which leads me to the old saying that friends don't let friends use friends.
On 26 Jul 2005 03:07:49 +0200, Gabriel Dos Reis
<[EMAIL PROTECTED]> wrote:
> Mike Stump <[EMAIL PROTECTED]> writes:
>
> | We are seeing tons of regressions (9 of 2377 for fink, over 100 or so
> | out of 8000 was it for internal projects) in the build state of
> | projects with code like:
> |
> | class bar {
> | friend class foo;
> | void baz(foo *x) {}
> | };
> |
> | from 4.0.0 in 4.0.1. This is really unfortunate. What we really
> | need is a warning (that can be easily turned off with a -Wno- switch)
> | for the next 2 years, and then an error, if you must. Doing this
> | from x.0.0 to x.0.1 is, uhm, well, more costly than if it had been
> | done in 4.0.0. :-(
> |
> | Thoughts?
>
> This area has been a historical weakness of GCC, causing us to reject
> valid-code or accept valid-code-with-wrong-semantics. As you point
> out above, it can can the overload set and such. Because the point of
> declaration is far away from the point of possible overload
> resolution, it is not all clear when an "invalid declaration accepted
> for past bug compayibility" should be or not be part of the overload
> set. You can warn, but it you turn it off, it is not obvious what the
> semantics should be.
>
> (This reminds me of the "implicit typename" stuff)
>
> -- Gaby
>