public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/44167] New: ICE in tsubst_copy at cp/pt.c:10077
@ 2010-05-17 13:50 marc dot hofmann at gmail dot com
2010-05-17 13:51 ` [Bug c++/44167] " marc dot hofmann at gmail dot com
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: marc dot hofmann at gmail dot com @ 2010-05-17 13:50 UTC (permalink / raw)
To: gcc-bugs
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2594 bytes --]
The following code (see below) triggers an ICE.
Command line:
g++ -save-temps -Wall -std=c++0x testcase.cc -o testcase
Error message:
testcase.cc: In function int main():
testcase.cc:42: internal compiler error: in tsubst_copy, at cp/pt.c:10077
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.4/README.Bugs> for instructions.
Code:
// file: testcase.cc
#include <tuple>
template<unsigned int N>
struct Apply_aux
{
template<typename F, typename T, typename... X>
static auto apply(F f, const T& t, X... x)
-> decltype(Apply_aux<N-1>::apply(f, t, std::get<N-1>(t), x...))
{
return Apply_aux<N-1>::apply(f, t, std::get<N-1>(t), x...);
}
};
template<>
struct Apply_aux<0>
{
template<typename F, typename T, typename... X>
static auto apply(F f, const T&, X... x)
-> decltype(f(x...))
{
return f(x...);
}
};
template<typename F, typename T>
auto apply(F f, const T& t)
-> decltype(Apply_aux<std::tuple_size<T>::value>::apply(f, t))
{
return Apply_aux<std::tuple_size<T>::value>::apply(f, t);
}
int f(int p1, double p2)
{
return 0;
}
int main()
{
apply(f, std::make_tuple(1, 2.0));
}
// end file: testcase.cc
Output of 'gcc -v':
Using built-in specs.
Target: i486-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.4.3-4ubuntu5'
--with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --enable-shared
--enable-multiarch --enable-linker-build-id --with-system-zlib
--libexecdir=/usr/lib --without-included-gettext --enable-threads=posix
--with-gxx-include-dir=/usr/include/c++/4.4 --program-suffix=-4.4 --enable-nls
--enable-clocale=gnu --enable-libstdcxx-debug --enable-plugin --enable-objc-gc
--enable-targets=all --disable-werror --with-arch-32=i486 --with-tune=generic
--enable-checking=release --build=i486-linux-gnu --host=i486-linux-gnu
--target=i486-linux-gnu
Thread model: posix
gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5)
Output of 'uname -a':
Linux wwz-comamh-166 2.6.32-22-generic #33-Ubuntu SMP Wed Apr 28 13:27:30 UTC
2010 i686 GNU/Linux
Thanks,
Marc
--
Summary: ICE in tsubst_copy at cp/pt.c:10077
Product: gcc
Version: 4.4.3
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: marc dot hofmann at gmail dot com
GCC target triplet: i486-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44167
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/44167] ICE in tsubst_copy at cp/pt.c:10077
2010-05-17 13:50 [Bug c++/44167] New: ICE in tsubst_copy at cp/pt.c:10077 marc dot hofmann at gmail dot com
@ 2010-05-17 13:51 ` marc dot hofmann at gmail dot com
2010-05-17 13:55 ` redi at gcc dot gnu dot org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: marc dot hofmann at gmail dot com @ 2010-05-17 13:51 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from marc dot hofmann at gmail dot com 2010-05-17 13:51 -------
Created an attachment (id=20680)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=20680&action=view)
Testcase source file.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44167
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/44167] ICE in tsubst_copy at cp/pt.c:10077
2010-05-17 13:50 [Bug c++/44167] New: ICE in tsubst_copy at cp/pt.c:10077 marc dot hofmann at gmail dot com
2010-05-17 13:51 ` [Bug c++/44167] " marc dot hofmann at gmail dot com
2010-05-17 13:55 ` redi at gcc dot gnu dot org
@ 2010-05-17 13:55 ` marc dot hofmann at gmail dot com
2010-05-17 14:01 ` redi at gcc dot gnu dot org
2010-05-17 14:03 ` redi at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: marc dot hofmann at gmail dot com @ 2010-05-17 13:55 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from marc dot hofmann at gmail dot com 2010-05-17 13:55 -------
Created an attachment (id=20682)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=20682&action=view)
Preprocessed file.
Created with:
g++ -save-temps -Wall -std=c++0x testcase.cc -o testcase
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44167
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/44167] ICE in tsubst_copy at cp/pt.c:10077
2010-05-17 13:50 [Bug c++/44167] New: ICE in tsubst_copy at cp/pt.c:10077 marc dot hofmann at gmail dot com
2010-05-17 13:51 ` [Bug c++/44167] " marc dot hofmann at gmail dot com
@ 2010-05-17 13:55 ` redi at gcc dot gnu dot org
2010-05-17 13:55 ` marc dot hofmann at gmail dot com
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: redi at gcc dot gnu dot org @ 2010-05-17 13:55 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from redi at gcc dot gnu dot org 2010-05-17 13:55 -------
*** Bug 44168 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44167
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/44167] ICE in tsubst_copy at cp/pt.c:10077
2010-05-17 13:50 [Bug c++/44167] New: ICE in tsubst_copy at cp/pt.c:10077 marc dot hofmann at gmail dot com
` (2 preceding siblings ...)
2010-05-17 13:55 ` marc dot hofmann at gmail dot com
@ 2010-05-17 14:01 ` redi at gcc dot gnu dot org
2010-05-17 14:03 ` redi at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: redi at gcc dot gnu dot org @ 2010-05-17 14:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from redi at gcc dot gnu dot org 2010-05-17 14:00 -------
4.5 doesn't ICE
pr44167.cc: In function 'int main()':
pr44167.cc:7:44: sorry, unimplemented: use of 'type_pack_expansion' in template
pr44167.cc:41:35: error: no matching function for call to 'apply(int (&)(int,
double), std::tuple<int, double>)'
possibly a dup of bug 43382
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44167
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/44167] ICE in tsubst_copy at cp/pt.c:10077
2010-05-17 13:50 [Bug c++/44167] New: ICE in tsubst_copy at cp/pt.c:10077 marc dot hofmann at gmail dot com
` (3 preceding siblings ...)
2010-05-17 14:01 ` redi at gcc dot gnu dot org
@ 2010-05-17 14:03 ` redi at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: redi at gcc dot gnu dot org @ 2010-05-17 14:03 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from redi at gcc dot gnu dot org 2010-05-17 14:03 -------
(In reply to comment #4)
>
> possibly a dup of bug 43382
actually I don't think it is a dup, because 43382 crashes with 4.5
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44167
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2010-05-17 14:03 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-05-17 13:50 [Bug c++/44167] New: ICE in tsubst_copy at cp/pt.c:10077 marc dot hofmann at gmail dot com
2010-05-17 13:51 ` [Bug c++/44167] " marc dot hofmann at gmail dot com
2010-05-17 13:55 ` redi at gcc dot gnu dot org
2010-05-17 13:55 ` marc dot hofmann at gmail dot com
2010-05-17 14:01 ` redi at gcc dot gnu dot org
2010-05-17 14:03 ` redi 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).