This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: c++/3518: [2003-05-03] default conversion applied too soon


Old Synopsis: [2003-01-02] default conversion applied too soon
New Synopsis: [2003-05-03] default conversion applied too soon

State-Changed-From-To: analyzed->feedback
State-Changed-By: bajo
State-Changed-When: Thu May 15 11:00:10 2003
State-Changed-Why:
    Nathan, I see what you are saying but I think the code is
    still legal. The applicable ctor is attempting to create
    a const qualified _reference_ to function type, which is
    a valid type. In fact, other compilers like Comeau/EDG
    instanciate the constructor with [T = void(void)]. 
    GCC compiles the code, but applies the default conversion
    too soon, so instanciates the template with [T = (void)(*)(void)]
    which is wrong. If you agree, we can rework a code snippet
    which fails if T is a function pointer so that we can
    properly detect the bug.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=3518


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]