C++ and useful error messages

pmscott pmscott@signal.dera.gov.uk
Fri Dec 22 02:10:00 GMT 2000


On Thursday, December 21, 2000 7:04 PM, Phil Edwards 
[SMTP:pedwards@disaster.jaj.com] wrote:
> On Thu, Dec 21, 2000 at 12:05:32PM -0000, pmscott wrote:
> > How about changing:
> >
> > emsg2.C:2: `vector' undeclared (first use this function)
> > emsg2.C:2: (Each undeclared identifier is reported only once for
> > each
> > function it appears in.)
> >
> > to:
> >
> > emsg2.C:2: `vector' undeclared (will not report it again for this
> > function)
>
> If you want to change anything, I would recommend one of
>
>   emsg2.C:2: `vector' undeclared (first use in this function)
>   emsg2.C:2: `vector' undeclared (first occurrence in this function)
>

I don't mind the wording, it's the use of a two line (three with the 
split brackets) error message for one error. I spend a lot of time 
stepping past the two extra 'error' lines during initial development, 
and it's quite tricky to specify automatically skipping them in every 
editor I've tried.

Paul


More information about the Gcc mailing list