public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/54890] New: Incorrect SFINAE Rejection
@ 2012-10-10 15:19 pmenso57 at comcast dot net
2012-10-10 16:00 ` [Bug c++/54890] " paolo.carlini at oracle dot com
` (9 more replies)
0 siblings, 10 replies; 11+ messages in thread
From: pmenso57 at comcast dot net @ 2012-10-10 15:19 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Bug #: 54890
Summary: Incorrect SFINAE Rejection
Classification: Unclassified
Product: gcc
Version: 4.7.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: pmenso57@comcast.net
When explicitly specifying the template parameters to a function template in
the following context, the compiler incorrectly removes the function from the
overload set for a substitution failure which should not exist.
struct A {
template<class T> struct apply { };
};
template<class T, class... U>
void f(typename T::template apply<U...>*) { }
int main() {
f<A, int>(nullptr);
return 0;
}
Output from the compiler is:
In function ‘int main()’:
error: no matching function for call to ‘f(std::nullptr_t)’
note: candidate is:
note: template<class T, class ... U> void f(typename T::apply<U ...>*)
note: template argument deduction/substitution failed:
note: mismatched types ‘A::apply<U ...>*’ and ‘std::nullptr_t’
Which I believe is incorrect.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
@ 2012-10-10 16:00 ` paolo.carlini at oracle dot com
2012-10-10 16:20 ` paolo.carlini at oracle dot com
` (8 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-10-10 16:00 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-10-10
Ever Confirmed|0 |1
--- Comment #1 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-10-10 16:00:31 UTC ---
Confirmed. Honestly, I don't think the issue has much to do with SFINAE, but
anyway seems easy to fix.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
2012-10-10 16:00 ` [Bug c++/54890] " paolo.carlini at oracle dot com
@ 2012-10-10 16:20 ` paolo.carlini at oracle dot com
2012-10-10 17:32 ` paolo.carlini at oracle dot com
` (7 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-10-10 16:20 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
AssignedTo|unassigned at gcc dot |paolo.carlini at oracle dot
|gnu.org |com
Target Milestone|--- |4.8.0
--- Comment #2 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-10-10 16:20:16 UTC ---
On it.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
2012-10-10 16:00 ` [Bug c++/54890] " paolo.carlini at oracle dot com
2012-10-10 16:20 ` paolo.carlini at oracle dot com
@ 2012-10-10 17:32 ` paolo.carlini at oracle dot com
2013-03-22 14:47 ` jakub at gcc dot gnu.org
` (6 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-10-10 17:32 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |NEW
AssignedTo|paolo.carlini at oracle dot |unassigned at gcc dot
|com |gnu.org
--- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-10-10 17:32:16 UTC ---
Nope, I don't have a fix forthcoming, sorry.
I thought something was wrong in unify, because NULLPTR_TYPE isn't explicitly
handled, but actually I think this should work for 0 too, not just for nullptr
(indeed, for non-variadic it does already)
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
` (2 preceding siblings ...)
2012-10-10 17:32 ` paolo.carlini at oracle dot com
@ 2013-03-22 14:47 ` jakub at gcc dot gnu.org
2013-05-31 11:00 ` jakub at gcc dot gnu.org
` (5 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-03-22 14:47 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.0 |4.8.1
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-03-22 14:45:50 UTC ---
GCC 4.8.0 is being released, adjusting target milestone.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
` (3 preceding siblings ...)
2013-03-22 14:47 ` jakub at gcc dot gnu.org
@ 2013-05-31 11:00 ` jakub at gcc dot gnu.org
2013-10-16 9:50 ` jakub at gcc dot gnu.org
` (4 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-05-31 11:00 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.1 |4.8.2
--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 4.8.1 has been released.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
` (4 preceding siblings ...)
2013-05-31 11:00 ` jakub at gcc dot gnu.org
@ 2013-10-16 9:50 ` jakub at gcc dot gnu.org
2014-05-12 8:26 ` paolo.carlini at oracle dot com
` (3 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2013-10-16 9:50 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.2 |4.8.3
--- Comment #6 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 4.8.2 has been released.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
` (5 preceding siblings ...)
2013-10-16 9:50 ` jakub at gcc dot gnu.org
@ 2014-05-12 8:26 ` paolo.carlini at oracle dot com
2014-05-13 15:59 ` paolo.carlini at oracle dot com
` (2 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: paolo.carlini at oracle dot com @ 2014-05-12 8:26 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |UNCONFIRMED
Ever confirmed|1 |0
--- Comment #7 from Paolo Carlini <paolo.carlini at oracle dot com> ---
Uhm, I note that both current clang and icc reject this.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
` (6 preceding siblings ...)
2014-05-12 8:26 ` paolo.carlini at oracle dot com
@ 2014-05-13 15:59 ` paolo.carlini at oracle dot com
2014-12-14 14:37 ` ville.voutilainen at gmail dot com
2014-12-15 15:24 ` [Bug c++/54890] [DR 1982] " jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: paolo.carlini at oracle dot com @ 2014-05-13 15:59 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jason at gcc dot gnu.org
--- Comment #8 from Paolo Carlini <paolo.carlini at oracle dot com> ---
Jason, can you help me (re-)triaging this?
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
` (7 preceding siblings ...)
2014-05-13 15:59 ` paolo.carlini at oracle dot com
@ 2014-12-14 14:37 ` ville.voutilainen at gmail dot com
2014-12-15 15:24 ` [Bug c++/54890] [DR 1982] " jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: ville.voutilainen at gmail dot com @ 2014-12-14 14:37 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Ville Voutilainen <ville.voutilainen at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ville.voutilainen at gmail dot com
--- Comment #9 from Ville Voutilainen <ville.voutilainen at gmail dot com> ---
Ping. I don't know what to make of this. The code looks reasonable, but both
gcc and clang reject it, failing deduction.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/54890] [DR 1982] Incorrect SFINAE Rejection
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
` (8 preceding siblings ...)
2014-12-14 14:37 ` ville.voutilainen at gmail dot com
@ 2014-12-15 15:24 ` jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2014-12-15 15:24 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54890
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution|--- |INVALID
Summary|Incorrect SFINAE Rejection |[DR 1982] Incorrect SFINAE
| |Rejection
--- Comment #10 from Jason Merrill <jason at gcc dot gnu.org> ---
This is
http://www.open-std.org/JTC1/SC22/WG21/docs/cwg_toc.html#1982
which was closed at the Urbana meeting.
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2014-12-15 15:24 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-10 15:19 [Bug c++/54890] New: Incorrect SFINAE Rejection pmenso57 at comcast dot net
2012-10-10 16:00 ` [Bug c++/54890] " paolo.carlini at oracle dot com
2012-10-10 16:20 ` paolo.carlini at oracle dot com
2012-10-10 17:32 ` paolo.carlini at oracle dot com
2013-03-22 14:47 ` jakub at gcc dot gnu.org
2013-05-31 11:00 ` jakub at gcc dot gnu.org
2013-10-16 9:50 ` jakub at gcc dot gnu.org
2014-05-12 8:26 ` paolo.carlini at oracle dot com
2014-05-13 15:59 ` paolo.carlini at oracle dot com
2014-12-14 14:37 ` ville.voutilainen at gmail dot com
2014-12-15 15:24 ` [Bug c++/54890] [DR 1982] " jason 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).