From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10340 invoked by alias); 14 Jul 2002 15:56: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 10290 invoked by uid 71); 14 Jul 2002 15:56:01 -0000 Resent-Date: 14 Jul 2002 15:56:01 -0000 Resent-Message-ID: <20020714155601.10289.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, "Martin v. Loewis" Received: (qmail 5612 invoked from network); 14 Jul 2002 15:51:27 -0000 Received: from unknown (HELO mailout09.sul.t-online.com) (194.25.134.84) by sources.redhat.com with SMTP; 14 Jul 2002 15:51:27 -0000 Received: from fwd09.sul.t-online.de by mailout09.sul.t-online.com with smtp id 17Tlef-0004uS-03; Sun, 14 Jul 2002 17:51:25 +0200 Received: from mira.informatik.hu-berlin.de (03047300346-0001@[217.232.19.220]) by fmrl09.sul.t-online.com with esmtp id 17TleV-22L9AuC; Sun, 14 Jul 2002 17:51:15 +0200 Received: from mira.informatik.hu-berlin.de (localhost [127.0.0.1]) by mira.informatik.hu-berlin.de (8.12.3/8.11.6/SuSE Linux 0.5) with ESMTP id g6EFpEmC020363 for ; Sun, 14 Jul 2002 17:51:14 +0200 Received: (from martin@localhost) by mira.informatik.hu-berlin.de (8.12.3/8.12.3/Submit) id g6EFpEjj020362; Sun, 14 Jul 2002 17:51:14 +0200 Message-Id: <200207141551.g6EFpEjj020362@mira.informatik.hu-berlin.de> Date: Sun, 14 Jul 2002 08:56:00 -0000 From: "Martin v. Loewis" To: gcc-gnats@gcc.gnu.org X-Send-Pr-Version: 3.113 Subject: c++/7307: -pedantic makes errors to warnings X-SW-Source: 2002-07/txt/msg00447.txt.bz2 List-Id: >Number: 7307 >Category: c++ >Synopsis: -pedantic makes errors to warnings >Confidential: no >Severity: non-critical >Priority: medium >Responsible: unassigned >State: open >Class: accepts-illegal >Submitter-Id: net >Arrival-Date: Sun Jul 14 08:56:01 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Martin v. Loewis >Release: 3.2 20020714 (experimental) >Organization: HUB >Environment: System: Linux mira 2.4.18-4GB #1 Wed Mar 27 13:57:05 UTC 2002 i686 unknown Architecture: i686 host: i686-pc-linux-gnu build: i686-pc-linux-gnu target: i686-pc-linux-gnu configured with: /usr/src/egcs/configure --prefix=/usr/local/newabi --enable-shared --enable-threads --enable-languages=c,c++,java : (reconfigured) : (reconfigured) /usr/src/egcs/configure --prefix=/usr/local/newabi --enable-shared --enable-threads --enable-languages=c,c++,java >Description: -pedantic changes the status of " field `char test::test' with same name as class" from error to warning, thus accepting the code under -pedantic, even though it is ill-formed. >How-To-Repeat: Compile the fragment struct test { char test; test(); }; with and without -pedantic: martin@mira:~/tmp> /usr/local/newabi/bin/g++ -S a.cc a.cc:3: error: field `char test::test' with same name as class martin@mira:~/tmp> /usr/local/newabi/bin/g++ -pedantic -S a.cc a.cc:3: warning: field `char test::test' with same name as class >Fix: >Release-Note: >Audit-Trail: >Unformatted: