This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] C++: avoid most reserved words as misspelling suggestions (PR c++/81610 and PR c++/80567)


On Wed, Nov 22, 2017 at 10:36 AM, David Malcolm <dmalcolm@redhat.com> wrote:
> PR c++/81610 and PR c++/80567 report problems where the C++ frontend
> suggested "if", "for" and "else" as corrections for misspelled variable
> names.

Hmm, what about cases where people are actually misspelling keywords?
Don't we want to handle that?

fi (true) { }
retrun 42;

In the PRs you mention, the actual identifiers are 1) missing
includes, which we should check first, and 2) pretty far from the
suggested keywords.

Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]