From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3204 invoked by alias); 5 Jun 2012 10:02:42 -0000 Received: (qmail 3187 invoked by uid 22791); 5 Jun 2012 10:02:40 -0000 X-SWARE-Spam-Status: No, hits=-4.3 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,KHOP_THREADED X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 05 Jun 2012 10:02:27 +0000 From: "manu at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/53573] template type dependent name resolution broken Date: Tue, 05 Jun 2012 10:02:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Keywords: X-Bugzilla-Severity: major X-Bugzilla-Who: manu at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: CC Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-06/txt/msg00230.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D53573 Manuel L=C3=B3pez-Ib=C3=A1=C3=B1ez changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |manu at gcc dot gnu.org --- Comment #7 from Manuel L=C3=B3pez-Ib=C3=A1=C3=B1ez 2012-06-05 10:02:25 UTC --- (In reply to comment #6) > The suggested work around in the error message 'adding -fpermissive' to > gcc-4.7.0 does not fix the problem as suggested by the error message. This > would suggest the compiler is not displaying the correct error message fo= r the > problem. >=20 > g++ -fpermissive test.cpp >=20 > Still generates: >=20 > test.cpp: In instantiation of =E2=80=98T f(T) [with T =3D int]=E2=80=99: > test.cpp:27:9: required from here > test.cpp:18:12: error: =E2=80=98g=E2=80=99 was not declared in this scope= , and no declarations > were found by argument-dependent lookup at the point of instantiation > [-fpermissive] > test.cpp:21:5: note: =E2=80=98int g(int)=E2=80=99 declared here, later in= the translation unit >=20 With GCC 4.8 revision 187148, -fpermissive generates a warning as it should. However, -fpermissive is not meant to fix anything, it is just a work-aroun= d to make non-standard code compile. I am not sure if this is a bug or not, so I am not touching the status.