public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
@ 2011-03-26 1:34 zeratul976 at hotmail dot com
2011-03-26 2:43 ` [Bug c++/48292] " zeratul976 at hotmail dot com
` (9 more replies)
0 siblings, 10 replies; 11+ messages in thread
From: zeratul976 at hotmail dot com @ 2011-03-26 1:34 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
Summary: [C++0x] "sorry, unimplemented: use of
'type_pack_expansion' in template"
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: zeratul976@hotmail.com
For the following code:
template <typename... Args> int g(Args...);
template <int N = 0>
struct A
{
template <typename... Args>
static auto f(Args... args) -> decltype(g(args...));
};
int main()
{
A<>::f();
return 0;
}
gcc gives the following errors:
test.cpp: In function 'int main()':
test.cpp:7:27: sorry, unimplemented: use of 'type_pack_expansion' in template
test.cpp:12:12: error: no matching function for call to 'A<>::f()'
test.cpp:12:12: note: candidate is:
test.cpp:7:55: note: template<class ... Args> static decltype (g(A::f::args
...)) A::f(Args ...) [with Args = {Args ...}, int N = 0, decltype (g(A::f::args
...)) = int]
Are there any plans to implement this?
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
@ 2011-03-26 2:43 ` zeratul976 at hotmail dot com
2011-03-26 4:03 ` zeratul976 at hotmail dot com
` (8 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: zeratul976 at hotmail dot com @ 2011-03-26 2:43 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
--- Comment #1 from Nathan Ridge <zeratul976 at hotmail dot com> 2011-03-25 23:52:22 UTC ---
Also, does someone know a workaround for this?
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
2011-03-26 2:43 ` [Bug c++/48292] " zeratul976 at hotmail dot com
@ 2011-03-26 4:03 ` zeratul976 at hotmail dot com
2011-03-28 16:47 ` paolo.carlini at oracle dot com
` (7 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: zeratul976 at hotmail dot com @ 2011-03-26 4:03 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
--- Comment #2 from Nathan Ridge <zeratul976 at hotmail dot com> 2011-03-26 00:02:32 UTC ---
Found a workaround:
#include <type_traits>
template <typename... Args>
int g(Args...);
template <typename... Args>
struct deduce
{
typedef decltype(g(std::declval<Args>()...)) type;
};
template <int N = 0>
struct A
{
template <typename... Args>
static typename deduce<Args...>::type f(Args... args);
};
int main()
{
A<>::f();
return 0;
}
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
2011-03-26 2:43 ` [Bug c++/48292] " zeratul976 at hotmail dot com
2011-03-26 4:03 ` zeratul976 at hotmail dot com
@ 2011-03-28 16:47 ` paolo.carlini at oracle dot com
2011-05-24 13:13 ` redi at gcc dot gnu.org
` (6 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: paolo.carlini at oracle dot com @ 2011-03-28 16:47 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
--- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> 2011-03-28 16:27:43 UTC ---
CC-ing Jason about this one too. By the way, isn't the first time this sorry
message surfaces, eg, Comment #4 in PR44167.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
` (2 preceding siblings ...)
2011-03-28 16:47 ` paolo.carlini at oracle dot com
@ 2011-05-24 13:13 ` redi at gcc dot gnu.org
2011-05-24 13:23 ` redi at gcc dot gnu.org
` (5 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: redi at gcc dot gnu.org @ 2011-05-24 13:13 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |marc.hofmann at gmail dot
| |com
--- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-05-24 12:44:35 UTC ---
*** Bug 44167 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
` (3 preceding siblings ...)
2011-05-24 13:13 ` redi at gcc dot gnu.org
@ 2011-05-24 13:23 ` redi at gcc dot gnu.org
2011-05-25 4:41 ` jason at gcc dot gnu.org
` (4 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: redi at gcc dot gnu.org @ 2011-05-24 13:23 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jason at gcc dot gnu.org
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-05-24 12:50:45 UTC ---
(In reply to comment #3)
> CC-ing Jason about this one too. By the way, isn't the first time this sorry
> message surfaces, eg, Comment #4 in PR44167.
... actually adding Jason to the CC list ;)
I've marked the other as a dup after comparing the results for both testcases
with G++ 4.4 and later versions.
Jason, is this likely to be easy to fix? I've been hitting this and PR 47335
while implementing std::allocator_traits. If they aren't likely to be fixed in
the near future I'll look into workarounds
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
` (4 preceding siblings ...)
2011-05-24 13:23 ` redi at gcc dot gnu.org
@ 2011-05-25 4:41 ` jason at gcc dot gnu.org
2011-05-25 9:29 ` redi at gcc dot gnu.org
` (3 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2011-05-25 4:41 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed| |2011.05.25 03:17:26
AssignedTo|unassigned at gcc dot |jason at gcc dot gnu.org
|gnu.org |
Ever Confirmed|0 |1
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
` (5 preceding siblings ...)
2011-05-25 4:41 ` jason at gcc dot gnu.org
@ 2011-05-25 9:29 ` redi at gcc dot gnu.org
2011-05-25 14:35 ` jason at gcc dot gnu.org
` (2 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: redi at gcc dot gnu.org @ 2011-05-25 9:29 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
--- Comment #6 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-05-25 09:05:15 UTC ---
Jason, I've found a decent workaround now so if you have higher priority issues
you'd rather fix then don't spend time on this one for my benefit. Thanks for
the incredible number of fixes you're making at the moment!
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
` (6 preceding siblings ...)
2011-05-25 9:29 ` redi at gcc dot gnu.org
@ 2011-05-25 14:35 ` jason at gcc dot gnu.org
2011-05-25 15:32 ` jason at gcc dot gnu.org
2011-05-25 15:35 ` jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2011-05-25 14:35 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
--- Comment #7 from Jason Merrill <jason at gcc dot gnu.org> 2011-05-25 14:32:09 UTC ---
Author: jason
Date: Wed May 25 14:32:06 2011
New Revision: 174201
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=174201
Log:
PR c++/48292
* pt.c (tsubst_decl) [PARM_DECL]: Handle partial instantiation of
function parameter pack.
(tsubst_pack_expansion): Likewise.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/variadic109.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/pt.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
` (7 preceding siblings ...)
2011-05-25 14:35 ` jason at gcc dot gnu.org
@ 2011-05-25 15:32 ` jason at gcc dot gnu.org
2011-05-25 15:35 ` jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2011-05-25 15:32 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
--- Comment #8 from Jason Merrill <jason at gcc dot gnu.org> 2011-05-25 15:26:18 UTC ---
Author: jason
Date: Wed May 25 15:26:14 2011
New Revision: 174207
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=174207
Log:
PR c++/48292
* pt.c (tsubst_decl) [PARM_DECL]: Handle partial instantiation of
function parameter pack.
(tsubst_pack_expansion): Likewise.
Added:
branches/gcc-4_6-branch/gcc/testsuite/g++.dg/cpp0x/variadic109.C
Modified:
branches/gcc-4_6-branch/gcc/cp/ChangeLog
branches/gcc-4_6-branch/gcc/cp/pt.c
branches/gcc-4_6-branch/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/48292] [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template"
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
` (8 preceding siblings ...)
2011-05-25 15:32 ` jason at gcc dot gnu.org
@ 2011-05-25 15:35 ` jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2011-05-25 15:35 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.6.1
--- Comment #9 from Jason Merrill <jason at gcc dot gnu.org> 2011-05-25 15:29:42 UTC ---
Fixed for 4.6.1.
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2011-05-25 15:32 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-26 1:34 [Bug c++/48292] New: [C++0x] "sorry, unimplemented: use of 'type_pack_expansion' in template" zeratul976 at hotmail dot com
2011-03-26 2:43 ` [Bug c++/48292] " zeratul976 at hotmail dot com
2011-03-26 4:03 ` zeratul976 at hotmail dot com
2011-03-28 16:47 ` paolo.carlini at oracle dot com
2011-05-24 13:13 ` redi at gcc dot gnu.org
2011-05-24 13:23 ` redi at gcc dot gnu.org
2011-05-25 4:41 ` jason at gcc dot gnu.org
2011-05-25 9:29 ` redi at gcc dot gnu.org
2011-05-25 14:35 ` jason at gcc dot gnu.org
2011-05-25 15:32 ` jason at gcc dot gnu.org
2011-05-25 15:35 ` 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).