public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/43559]  New: Overloaded template functions became ambiguous
@ 2010-03-28 19:04 sefi at s-e-f-i dot de
  2010-03-28 19:28 ` [Bug c++/43559] " paolo dot carlini at oracle dot com
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: sefi at s-e-f-i dot de @ 2010-03-28 19:04 UTC (permalink / raw)
  To: gcc-bugs

The following code used to work with gcc-4.4.3.
The Comeau online compiler also accepts it.
But with the gcc-4.5 trunk, it is rejected as ambiguous.


template<typename T, typename U> void f(U&) { }
template<typename T, typename U> void f(T const&) { }

int main()
{
        int a;
        f<int, int const>(a);
}

This is a reduced test case from boost.phoenix.
I'm not completely sure if gcc-4.5 is now right or wrong. Please investigate.


-- 
           Summary: Overloaded template functions became ambiguous
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: sefi at s-e-f-i dot de


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


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

end of thread, other threads:[~2010-03-30 19:47 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-28 19:04 [Bug c++/43559] New: Overloaded template functions became ambiguous sefi at s-e-f-i dot de
2010-03-28 19:28 ` [Bug c++/43559] " paolo dot carlini at oracle dot com
2010-03-28 19:33 ` schaub-johannes at web dot de
2010-03-30 13:47 ` [Bug c++/43559] [4.5 Regression] " rguenth at gcc dot gnu dot org
2010-03-30 16:46 ` jason at gcc dot gnu dot org
2010-03-30 19:40 ` jason at gcc dot gnu dot org
2010-03-30 19:47 ` jason 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).