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]

[Bug c++/19092] g++ accepts code that violates 14.6.4.2


------- Additional Comments From redi at gcc dot gnu dot org  2005-07-07 00:25 -------
Keywords should include "wrong-code", this program should return 0:

static int f(int i)
{
    return 1;
}

int f(long l)
{
    return 0;
}

template <typename T>
    int g(T t)
    {
       return f(t);
    }

int main()
{
   return g(0);
}


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |redi at gcc dot gnu dot org


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


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