From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4174 invoked by alias); 25 Dec 2002 15:26:08 -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 4155 invoked by uid 71); 25 Dec 2002 15:26:08 -0000 Resent-Date: 25 Dec 2002 15:26:08 -0000 Resent-Message-ID: <20021225152608.4154.qmail@sources.redhat.com> Resent-From: gcc-gnats@gcc.gnu.org (GNATS Filer) Resent-Cc: gcc-prs@gcc.gnu.org, gcc-bugs@gcc.gnu.org Resent-Reply-To: gcc-gnats@gcc.gnu.org, sneechy@hotmail.com Received: (qmail 3746 invoked by uid 61); 25 Dec 2002 15:20:01 -0000 Message-Id: <20021225152001.3745.qmail@sources.redhat.com> Date: Wed, 25 Dec 2002 07:26:00 -0000 From: sneechy@hotmail.com Reply-To: sneechy@hotmail.com To: gcc-gnats@gcc.gnu.org X-Send-Pr-Version: gnatsweb-2.9.3 (1.1.1.1.2.31) Subject: c++/9057: partial template specialization appears to be ignored X-SW-Source: 2002-12/txt/msg01283.txt.bz2 List-Id: >Number: 9057 >Category: c++ >Synopsis: partial template specialization appears to be ignored >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: rejects-legal >Submitter-Id: net >Arrival-Date: Wed Dec 25 07:26:05 PST 2002 >Closed-Date: >Last-Modified: >Originator: sneechy@hotmail.com >Release: gcc version 3.2 (mingw special 20020817-1) >Organization: >Environment: gcc version 3.2 (mingw special 20020817-1) Configured with: ../gcc/configure --with-gcc --with-gnu-ld --with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls --enable-languages=f77,c++,objc,ada --disable-win32-registry --disable-shared Thread model: win32 >Description: Compiling the following code: template struct A { template struct B; enum { i = 0 }; template struct B {}; }; int j = sizeof(A::B<0, void>); results in the following error (on the 'int j = ..' line): `sizeof' applied to incomplete type `A::B<0, void>' I've lozalized and simplified the problem as much as I could. Everything that is left somehow contributes to the conditions that create this problem. Somehow the B partial specialization appears to be ignored because it was specialized using an enumeration value from this particular context. G++ does accept the code if the enumeration is moved outside A. Comeau compiles the code without problems. >How-To-Repeat: See description. >Fix: No idea. >Release-Note: >Audit-Trail: >Unformatted: