From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6886 invoked by alias); 14 Jul 2002 08:46:03 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 6865 invoked by uid 71); 14 Jul 2002 08:46:02 -0000 Resent-Date: 14 Jul 2002 08:46:02 -0000 Resent-Message-ID: <20020714084602.6860.qmail@sources.redhat.com> Resent-From: gcc-gnats@gcc.gnu.org (GNATS Filer) Resent-To: nobody@gcc.gnu.org Resent-Cc: gcc-prs@gcc.gnu.org, gcc-bugs@gcc.gnu.org Resent-Reply-To: gcc-gnats@gcc.gnu.org, een@cs.chalmers.se Received: (qmail 3908 invoked by uid 61); 14 Jul 2002 08:38:02 -0000 Message-Id: <20020714083802.3907.qmail@sources.redhat.com> Date: Sun, 14 Jul 2002 01:46:00 -0000 From: een@cs.chalmers.se Reply-To: een@cs.chalmers.se To: gcc-gnats@gcc.gnu.org X-Send-Pr-Version: gnatsweb-2.9.3 (1.1.1.1.2.31) Subject: c++/7303: Internal error #75 -- typedef + templates + typeof X-SW-Source: 2002-07/txt/msg00434.txt.bz2 List-Id: >Number: 7303 >Category: c++ >Synopsis: Internal error #75 -- typedef + templates + typeof >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: sw-bug >Submitter-Id: net >Arrival-Date: Sun Jul 14 01:46:01 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Niklas Een >Release: gcc version 2.96 20000731 >Organization: >Environment: >Description: Doing meta programming without __if_exists (as in VC, when are you going to add it?) takes clever tricks. The only solution I could come up with results in internal compiler error :-(. Here is a minimal program that causes the bug: struct A { int x; }; template struct B { typedef typeof(T().x) y; }; int main(void) { B dummy; return 0; } >How-To-Repeat: Just compile the above lines. >Fix: >Release-Note: >Audit-Trail: >Unformatted: ----gnatsweb-attachment---- Content-Type: application/octet-stream; name="bug.C" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="bug.C" c3RydWN0IEEgewogICAgaW50ICAgICB4Owp9OwoKCnRlbXBsYXRlIDxjbGFzcyBUPgpzdHJ1Y3Qg QiB7CiAgICB0eXBlZGVmIHR5cGVvZihUKCkueCkgICB5Owp9OwoKCgppbnQgbWFpbih2b2lkKQp7 CiAgICBCPEE+ICAgIGR1bW15OwoKICAgIHJldHVybiAwOwp9Cg==