This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [C++ PATCH]: warning on implicit float->int
- To: Gabriel Dos Reis <gdr at codesourcery dot com>
- Subject: Re: [C++ PATCH]: warning on implicit float->int
- From: Jason Merrill <jason at cygnus dot com>
- Date: 03 Mar 2000 09:19:55 -0800
- Cc: Nathan Sidwell <nathan at codesourcery dot com>, gcc-patches at gcc dot gnu dot org, j dot kuipers at chello dot nl
- References: <38BA49F3.FE2D3D78@codesourcery.com> <u9aekljlvg.fsf@yorick.cygnus.com> <38BF92BA.9799E4F2@codesourcery.com> <flwvnkdrj4.fsf@poivre.cmla.ens-cachan.fr>
>>>>> Gabriel Dos Reis <gdr@codesourcery.com> writes:
> ! ... In convert_for_initialization we need the same thing, and we
> | have the hack of saving the error count, calling the functions and then
> | seeing if we issued any errors, and if so emit some context. Ug!
> | I think the right thing is to implement a little context stack for diagnostics
> | which we can push closures onto. Then when emitting a diagnostic we simply
> | invoke the top closure to generate the context information. No need to keep
> | passing the stuff around or saving error counts. Does that sound good?
> I would prefer not to waste resource on this stuff. I would prefer a
> recursive descent parser (isn't there a plan to rewrite the parser?).
> At that point we'll have the context.
I don't see how that follows; we would still want information about which
argument we're dealing with.
Nathan, I like your idea. I'd hook it into lang_print_error_function, much
like maybe_print_template_context.
> Maybe it is time to start to reimplement the parser. Mark, Jason?
Long since time.
Jason