diff options
author | Kaelyn Uhrain <rikka@google.com> | 2011-10-11 01:02:41 +0000 |
---|---|---|
committer | Kaelyn Uhrain <rikka@google.com> | 2011-10-11 01:02:41 +0000 |
commit | fac9467d1676dc05761e12e41e13e01a3a3da52b (patch) | |
tree | 12fc43c9043270ebfd6db7342c4c8d1ae1f34f8b /include/clang/Parse/Parser.h | |
parent | e1e7862586b6077a68dea05bcdbb67f63be3057d (diff) |
Add typo correction for type names.
The main motivation was to do typo correction in C++ "new" statements,
though picking it up in other places where type names are expected was
pretty much a freebie.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141621 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Parse/Parser.h')
-rw-r--r-- | include/clang/Parse/Parser.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/clang/Parse/Parser.h b/include/clang/Parse/Parser.h index a1f602c72a..e1e2402a2c 100644 --- a/include/clang/Parse/Parser.h +++ b/include/clang/Parse/Parser.h @@ -436,7 +436,10 @@ private: Tok.setAnnotationValue(ER.get()); } - bool TryAnnotateTypeOrScopeToken(bool EnteringContext = false); + // If NeedType is true, then TryAnnotateTypeOrScopeToken will try harder to + // find a type name by attempting typo correction. + bool TryAnnotateTypeOrScopeToken(bool EnteringContext = false, + bool NeedType = false); bool TryAnnotateCXXScopeToken(bool EnteringContext = false); /// TryAltiVecToken - Check for context-sensitive AltiVec identifier tokens, |