Home
last modified time | relevance | path

Searched refs:Typo (Results 1 – 25 of 33) sorted by relevance

12

/llvm-project-15.0.7/clang/include/clang/Sema/
H A DTypoCorrection.h285 explicit CorrectionCandidateCallback(IdentifierInfo *Typo = nullptr,
287 : Typo(Typo), TypoNNS(TypoNNS) {} in Typo() function
322 void setTypoName(IdentifierInfo *II) { Typo = II; } in setTypoName()
341 return Typo && candidate.isResolved() && !candidate.requiresImport() && in MatchesTypo()
342 candidate.getCorrectionAsIdentifierInfo() == Typo && in MatchesTypo()
348 IdentifierInfo *Typo; variable
354 explicit DefaultFilterCCC(IdentifierInfo *Typo = nullptr,
356 : CorrectionCandidateCallback(Typo, TypoNNS) {} in CorrectionCandidateCallback() argument
H A DSemaInternal.h98 : Typo(TypoName.getName().getAsIdentifierInfo()), CurrentTCIndex(0), in TypoCorrectionConsumer()
296 IdentifierInfo *Typo; variable
H A DExternalSemaSource.h210 virtual TypoCorrection CorrectTypo(const DeclarationNameInfo &Typo, in CorrectTypo() argument
H A DMultiplexExternalSemaSource.h344 TypoCorrection CorrectTypo(const DeclarationNameInfo &Typo,
/llvm-project-15.0.7/clang-tools-extra/clang-include-fixer/
H A DIncludeFixer.cpp185 const DeclarationNameInfo &Typo, int LookupKind, Scope *S, CXXScopeSpec *SS, in CorrectTypo() argument
211 if (!CI->getSourceManager().isWrittenInMainFile(Typo.getLoc())) in CorrectTypo()
264 Typo.getLoc()); in CorrectTypo()
268 } else if (Typo.getName().isIdentifier() && !Typo.getLoc().isMacroID()) { in CorrectTypo()
270 CharSourceRange::getTokenRange(Typo.getBeginLoc(), Typo.getEndLoc()); in CorrectTypo()
275 QueryString = Typo.getAsString(); in CorrectTypo()
276 SymbolRange = CreateToolingRange(Typo.getLoc()); in CorrectTypo()
285 TypoCorrection Correction(Typo.getName()); in CorrectTypo()
286 Correction.setCorrectionRange(SS, Typo); in CorrectTypo()
287 FileID FID = SM.getFileID(Typo.getLoc()); in CorrectTypo()
H A DIncludeFixer.h106 clang::TypoCorrection CorrectTypo(const DeclarationNameInfo &Typo,
/llvm-project-15.0.7/clang/lib/AST/
H A DCommentCommandTraits.cpp47 CommandTraits::getTypoCorrectCommandInfo(StringRef Typo) const { in getTypoCorrectCommandInfo()
50 if (Typo.size() <= 1) in getTypoCorrectCommandInfo()
62 unsigned MinPossibleEditDistance = abs((int)Name.size() - (int)Typo.size()); in getTypoCorrectCommandInfo()
64 unsigned EditDistance = Typo.edit_distance(Name, true, BestEditDistance); in getTypoCorrectCommandInfo()
H A DCommentSema.cpp984 StringRef Typo; member in clang::comments::__anon5983895a0211::SimpleTypoCorrector
992 explicit SimpleTypoCorrector(StringRef Typo) in SimpleTypoCorrector() argument
993 : BestDecl(nullptr), Typo(Typo), MaxEditDistance((Typo.size() + 2) / 3), in SimpleTypoCorrector()
1019 unsigned MinPossibleEditDistance = abs((int)Name.size() - (int)Typo.size()); in addDecl()
1021 Typo.size() / MinPossibleEditDistance < 3) in addDecl()
1024 unsigned EditDistance = Typo.edit_distance(Name, true, MaxEditDistance); in addDecl()
1034 StringRef Typo, in correctTypoInParmVarReference() argument
1036 SimpleTypoCorrector Corrector(Typo); in correctTypoInParmVarReference()
1099 StringRef Typo, in correctTypoInTParamReference() argument
1101 SimpleTypoCorrector Corrector(Typo); in correctTypoInTParamReference()
/llvm-project-15.0.7/clang/test/Index/
H A Dpreamble-with-implicit-import.m3 // CHECK: error: declaration of 'Typo' must be imported
4 // CHECK: error: declaration of 'Typo' must be imported
/llvm-project-15.0.7/clang/unittests/Sema/
H A DExternalSemaSourceTest.cpp107 TypoCorrection CorrectTypo(const DeclarationNameInfo &Typo, int LookupKind, in CorrectTypo() argument
113 if (CurrentSema && Typo.getName().getAsString() == CorrectFrom) { in CorrectTypo()
123 NamespaceDecl::Create(Context, DestContext, false, Typo.getBeginLoc(), in CorrectTypo()
124 Typo.getLoc(), ToIdent, nullptr); in CorrectTypo()
149 TypoCorrection CorrectTypo(const DeclarationNameInfo &Typo, int LookupKind, in CorrectTypo() argument
155 if (CurrentSema && Typo.getName().getAsString() == CorrectFrom) { in CorrectTypo()
/llvm-project-15.0.7/clang-tools-extra/clangd/
H A DIncludeFixer.cpp459 collectAccessibleScopes(Sema &Sem, const DeclarationNameInfo &Typo, Scope *S, in collectAccessibleScopes() argument
493 TypoCorrection CorrectTypo(const DeclarationNameInfo &Typo, int LookupKind, in CorrectTypo() argument
498 dlog("CorrectTypo: {0}", Typo.getAsString()); in CorrectTypo()
502 if (!isInsideMainFile(Typo.getLoc(), SemaPtr->SourceMgr)) in CorrectTypo()
506 SemaPtr->SourceMgr, Typo, SS, SemaPtr->LangOpts, in CorrectTypo()
514 Unresolved.Loc = Typo.getBeginLoc(); in CorrectTypo()
522 *SemaPtr, Typo, S, static_cast<Sema::LookupNameKind>(LookupKind)); in CorrectTypo()
/llvm-project-15.0.7/clang/test/Index/Inputs/
H A Dpreamble-with-implicit-import.h4 void useTypeFromB(Typo *);
H A Dpreamble-with-implicit-import-B.h3 typedef struct { char x; } Typo; typedef
/llvm-project-15.0.7/clang/include/clang/AST/
H A DCommentSema.h236 unsigned correctTypoInParmVarReference(StringRef Typo,
244 StringRef Typo,
H A DCommentCommandTraits.h151 const CommandInfo *getTypoCorrectCommandInfo(StringRef Typo) const;
/llvm-project-15.0.7/clang/test/SemaCXX/
H A Dfunctional-cast.cpp317 typedef itn Typo; // expected-error {{unknown type name 'itn'}} in crash_on_invalid_1() typedef
318 (void)Typo(1); // used to crash in crash_on_invalid_1()
/llvm-project-15.0.7/llvm/test/Object/
H A Dnm-tapi-invalids.test10 # Typo Check
/llvm-project-15.0.7/clang/lib/Sema/
H A DSemaLookup.cpp4545 if (!LookupResult::isVisible(SemaRef, ND) && Name != Typo) in FoundDecl()
4567 StringRef TypoStr = Typo->getName(); in addName()
4587 StringRef TypoStr = Typo->getName(); in addCorrection()
4757 unsigned TypoLen = Typo->getName().size(); in performQualifiedLookups()
4783 if (QR.getCorrectionAsIdentifierInfo() != Typo && TmpED && in performQualifiedLookups()
4802 OldOStream << Typo->getName(); in performQualifiedLookups()
5173 IdentifierInfo *Typo = TypoName.getName().getAsIdentifierInfo(); in makeTypoCorrectionConsumer() local
5174 if (!Typo) in makeTypoCorrectionConsumer()
5215 getModuleLoader().lookupMissingImports(Typo->getName(), in makeTypoCorrectionConsumer()
5369 unsigned TypoLen = Typo->getName().size(); in CorrectTypo()
[all …]
H A DMultiplexExternalSemaSource.cpp315 const DeclarationNameInfo &Typo, in CorrectTypo() argument
322 if (TypoCorrection C = Sources[I]->CorrectTypo(Typo, LookupKind, S, SS, CCC, in CorrectTypo()
/llvm-project-15.0.7/clang/test/SemaObjC/
H A Dtypo-correction.m55 // Typo correction for a property when it has as correction candidates
H A Dparameterized_classes.m226 // Typo correction: protocol bias.
229 // Typo correction: type bias.
233 // Typo correction: bias set by correction itself to a protocol.
236 // Typo correction: bias set by correction itself to a type.
/llvm-project-15.0.7/clang/test/SemaObjCXX/
H A Dtypo-correction.mm41 // Typo correction for a property when it has as correction candidates
/llvm-project-15.0.7/clang/test/CXX/except/except.spec/
H A Dp14.cpp123 Typo foo(); // expected-error{{unknown type name 'Typo'}}
/llvm-project-15.0.7/lldb/source/Plugins/ExpressionParser/Clang/
H A DASTUtils.h545 CorrectTypo(const clang::DeclarationNameInfo &Typo, int LookupKind, in CorrectTypo() argument
552 Source->CorrectTypo(Typo, LookupKind, S, SS, CCC, in CorrectTypo()
/llvm-project-15.0.7/clang-tools-extra/unittests/clang-include-fixer/
H A DIncludeFixerTest.cpp118 TEST(IncludeFixer, Typo) { in TEST() argument

12