Bug#293076: g++-3.3 uninformative error when base class missing
tags 293076 + upstream
tags 293076 + fixed-upstream
retitle 293076 [fixed in 3.4] g++-3.3: uninformative error when base class missing
thanks
Greg Kochanski <gpk@kochanski.org> writes:
> In the following program, the base class is missing.
> G++ gives a wimpy error message:
>
> bug.c:3: error: parse error before `{' token
>
> It could do much better. Syntactically, there aren't a lot of
> options for 'z'. A better error message might be something like
>
> bug.c:3: error: parse error between ':' and '{'. Expecting that "z" would be the name of a class.
>
>
> Here's the code:
>
> class y: z {
> public:
> };
g++ 3.4 says:
test.cc:2: error: expected class-name before '{' token
which seems OK.
--
Falk
Reply to: