From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22874 invoked by alias); 21 Jul 2005 23:11:54 -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 22743 invoked by uid 48); 21 Jul 2005 23:11:41 -0000 Date: Thu, 21 Jul 2005 23:18:00 -0000 Message-ID: <20050721231141.22742.qmail@sourceware.org> From: "bangerth at dealii dot org" To: gcc-bugs@gcc.gnu.org In-Reply-To: <20050721143121.22590.igodard@pacbell.net> References: <20050721143121.22590.igodard@pacbell.net> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug c++/22590] parser does not recover well after error X-Bugzilla-Reason: CC X-SW-Source: 2005-07/txt/msg02645.txt.bz2 List-Id: ------- Additional Comments From bangerth at dealii dot org 2005-07-21 23:11 ------- With Andrew's little testcase, I get g/x> cat > x.cc include "core.hh" typedef unsigned int size_t; namespace std { using ::size_t; } g/x> /home/bangerth/bin/gcc-4.1-pre/bin/c++ -c x.cc x.cc:1: error: expected constructor, destructor, or type conversion before string constant x.cc:5: error: ‘::size_t‘ has not been declared I guess that's as good as it gets: it doesn't understand your include statement (understandably so) and then keeps reading. Since there is no semicolon after the botched include, it skips the rest of the presumed statement until after your declaration of ::size_t. The next error is where you use ::size_t, which of course it doesn't know. What's wrong with this? W. -- What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |WAITING http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22590