From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1209 invoked by alias); 20 Oct 2007 21:45:23 -0000 Received: (qmail 943 invoked by uid 48); 20 Oct 2007 21:45:12 -0000 Date: Sat, 20 Oct 2007 21:45:00 -0000 Subject: [Bug c++/33838] New: [4.3 regresssion] ICE with invalid use of decltype X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "reichelt at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2007-10/txt/msg01842.txt.bz2 The following invalid code snippet triggers an ICE on mainline: =============================== template struct A { __decltype (T* foo()); }; =============================== bug.cc:3: error: expected primary-expression before '*' token bug.cc:3: error: there are no arguments to 'foo' that depend on a template parameter, so a declaration of 'foo' must be available bug.cc:3: error: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated) bug.cc:3: internal compiler error: Segmentation fault Please submit a full bug report, [etc.] The problem appeared between 2007-07-16 and 2007-08-15, presumably with the introduction of decltype: 2007-07-27 Douglas Gregor * typeck.c (structural_comptypes): Compare DECLTYPE_TYPE nodes. * cp-tree.def (DECLTYPE_TYPE): New. * error.c (dump_type): Dump DECLTYPE_TYPE nodes. ... -- Summary: [4.3 regresssion] ICE with invalid use of decltype Product: gcc Version: 4.3.0 Status: UNCONFIRMED Keywords: ice-on-invalid-code, error-recovery, monitored Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: reichelt at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33838