This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/45520] New: Regression: compiler segmentation fault on decltype from a dereferenced map iterator
- From: "qduaty at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Sep 2010 14:41:22 -0000
- Subject: [Bug c++/45520] New: Regression: compiler segmentation fault on decltype from a dereferenced map iterator
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The compiler says: main.cc:7:35: internal compiler error: Segmentation fault
The map must be a class member to reproduce the bug.
If the decltype is not in a lambda, but a method argument, a different message
appears:
main.cc:6:32: internal compiler error: in tree_low_cst, at tree.c:6328
This code compiled correctly with g++ 4.5.0.
File content:
#include <map>
struct S {
std::map < void*, int> Map;
void f() {
auto lambda=[&](decltype(*Map.begin()) & i) { };
}
};
--
Summary: Regression: compiler segmentation fault on decltype from
a dereferenced map iterator
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: qduaty at gmail dot com
GCC host triplet: i686-pc-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45520