public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/28588]  New: static private function
@ 2006-08-03 19:30 dushistov at mail dot ru
  2006-08-03 20:16 ` [Bug c++/28588] [4.0/4.1/4.2 Regression] " pinskia at gcc dot gnu dot org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: dushistov at mail dot ru @ 2006-08-03 19:30 UTC (permalink / raw)
  To: gcc-bugs

$ cat test.cpp 
class Foo { static void f() {} };

int main()
{
        Foo foo;
        void (*f)();
        f = foo.f;
        return 0;
}

$ g++ -Wall test.cpp && echo "success"
success

If trying compile it with another compiler
http://cpp.sourceforge.net/?show=18471
I got something like this:

ComeauTest.c(7): error: function "Foo::f" is inaccessible
          f = foo.f;


-- 
           Summary: static private function
           Product: gcc
           Version: 4.1.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dushistov at mail dot ru


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28588


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2006-09-09  5:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-08-03 19:30 [Bug c++/28588] New: static private function dushistov at mail dot ru
2006-08-03 20:16 ` [Bug c++/28588] [4.0/4.1/4.2 Regression] " pinskia at gcc dot gnu dot org
2006-08-20 22:26 ` mmitchel at gcc dot gnu dot org
2006-08-25 18:16 ` mmitchel at gcc dot gnu dot org
2006-08-26 16:23 ` mmitchel at gcc dot gnu dot org
2006-08-26 16:34 ` [Bug c++/28588] [4.0/4.1 " mmitchel at gcc dot gnu dot org
2006-09-09  5:01 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).