From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23407 invoked by alias); 17 May 2004 03:48:44 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 23363 invoked by uid 48); 17 May 2004 03:48:43 -0000 Date: Mon, 17 May 2004 19:16:00 -0000 Message-ID: <20040517034843.23362.qmail@sourceware.org> From: "gianni at mariani dot ws" To: gcc-bugs@gcc.gnu.org In-Reply-To: <20040516212738.15480.gianni@mariani.ws> References: <20040516212738.15480.gianni@mariani.ws> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug c++/15480] ICE with sizeof(T().f()) as template parameter in function resolution X-Bugzilla-Reason: CC X-SW-Source: 2004-05/txt/msg01804.txt.bz2 List-Id: ------- Additional Comments From gianni at mariani dot ws 2004-05-17 03:48 ------- I get this error when removing the templates: xx6.cpp:43: sorry, unimplemented: call_expr cannot be mangled due to a defect in the C++ ABI ------------------------------ typedef char MPT_False; typedef int MPT_True; template struct MPT_IntToType { typedef char type[ 1 ]; }; struct B { int Function(); }; struct DerivedClass_B : B { }; struct FinderM { template static MPT_True finder( const w_T *, typename MPT_IntToType< sizeof(static_cast(0)->Function()) >::type * = 0 ); static MPT_False finder( const B * ); }; bool value = sizeof( FinderM::finder( static_cast(0) ) ) == sizeof( MPT_True ); ------------------------------ -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15480