This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/8280] friend declaration introduces class name into namespace scope
- From: "bernie at develer dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 17 Dec 2003 23:07:35 -0000
- Subject: [Bug c++/8280] friend declaration introduces class name into namespace scope
- References: <20021018165600.8280.dbaron@fas.harvard.edu>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From bernie at develer dot com 2003-12-17 23:07 -------
This does _not_ seem a duplicate of PR1016 to me.
In this case GCC is too permissive in a way that
doesn't concern namespaces.
Here's a testcase that should fail but doesn't:
class Foo
{
// No prototype for bar() ever given
friend void bar(int);
};
void some_function()
{
bar(10); // No error for undeclared function!
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=8280