public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/67928] New: Ambiguous call not diagnosed
@ 2015-10-12 9:35 alexpolt at yandex dot ru
2024-04-05 22:53 ` [Bug c++/67928] " pinskia at gcc dot gnu.org
0 siblings, 1 reply; 2+ messages in thread
From: alexpolt at yandex dot ru @ 2015-10-12 9:35 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67928
Bug ID: 67928
Summary: Ambiguous call not diagnosed
Product: gcc
Version: 5.2.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: alexpolt at yandex dot ru
Target Milestone: ---
In the following code the call to 'print' is not diagnosed as ambiguous. Clang
is ok.
void print() {}
template<class T, class... types>
void print( const T& arg1, const types&... args );
template<class T, class... types, unsigned U = sizeof(&T::to_string)>
void print( const T& arg1, const types&... args ) {
print( args... );
}
template<class T, class... types>
void print( const T& arg1, const types&... args ) {
print( args... );
}
struct test { void to_string() const {} };
int main() {
print( test{}, 1 );
}
gcc version 5.2.0 (GCC-explorer-build)
Target: x86_64-linux-gnu
Options: -O2 -std=c++14 -Wall -pedantic
Link to godbolt: http://goo.gl/iBMNJK
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug c++/67928] Ambiguous call not diagnosed
2015-10-12 9:35 [Bug c++/67928] New: Ambiguous call not diagnosed alexpolt at yandex dot ru
@ 2024-04-05 22:53 ` pinskia at gcc dot gnu.org
0 siblings, 0 replies; 2+ messages in thread
From: pinskia at gcc dot gnu.org @ 2024-04-05 22:53 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67928
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=80871
Target Milestone|--- |10.2
Status|NEW |RESOLVED
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Fixed in GCC 10.2.0 and GCC 11+.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-04-05 22:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-12 9:35 [Bug c++/67928] New: Ambiguous call not diagnosed alexpolt at yandex dot ru
2024-04-05 22:53 ` [Bug c++/67928] " pinskia at gcc dot gnu.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).