From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30835 invoked by alias); 24 Apr 2003 08:36:02 -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 30804 invoked by uid 71); 24 Apr 2003 08:36:01 -0000 Resent-Date: 24 Apr 2003 08:36:01 -0000 Resent-Message-ID: <20030424083601.30803.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, bartoschek@gmx.de Received: (qmail 29998 invoked by uid 48); 24 Apr 2003 08:30:59 -0000 Message-Id: <20030424083059.29997.qmail@sources.redhat.com> Date: Thu, 24 Apr 2003 08:36:00 -0000 From: bartoschek@gmx.de Reply-To: bartoschek@gmx.de To: gcc-gnats@gcc.gnu.org X-Send-Pr-Version: gnatsweb-2.9.3 (1.1.1.1.2.31) Subject: c++/10477: Function call not recognized as template X-SW-Source: 2003-04/txt/msg01023.txt.bz2 List-Id: >Number: 10477 >Category: c++ >Synopsis: Function call not recognized as template >Confidential: no >Severity: non-critical >Priority: medium >Responsible: unassigned >State: open >Class: rejects-legal >Submitter-Id: net >Arrival-Date: Thu Apr 24 08:36:01 UTC 2003 >Closed-Date: >Last-Modified: >Originator: bartoschek@gmx.de >Release: 3.2.3 >Organization: >Environment: RedHat 9 and Suse Linux 8.2 >Description: The attached code does not compile. And gives the error error.C: In member function `void B::f(int)': error.C:15: parse error before `>' token The fist < is recognized as operator< and not as the beginning of template arguments. If you delete Line 11: class C {}; the code compiles fine. Class C should not affect in any way the behaviour of void B::f(int). If you delete Class A and use Class C as a template argument: void B::f(int a) { f(); } it still does not compile. (class C has to be defined between class B and void B::f(int a)) >How-To-Repeat: g++ -c error.C >Fix: >Release-Note: >Audit-Trail: >Unformatted: ----gnatsweb-attachment---- Content-Type: text/x-c++src; name="error.C" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="error.C" Y2xhc3MgQSB7fTsKCmNsYXNzIEIKewpwdWJsaWM6CiAgIHRlbXBsYXRlPHR5cGVuYW1lIFQ+CiAg IGlubGluZSB2b2lkIGYoKSB7fQogICBpbmxpbmUgdm9pZCBmKGludCBhKTsKfTsKCmNsYXNzIEMg e307Cgp2b2lkIEI6OmYoaW50IGEpCnsKICAgZjxBPigpOwp9Cg==