Home
last modified time | relevance | path

Searched refs:DiagLoc (Results 1 – 25 of 28) sorted by relevance

12

/llvm-project-15.0.7/clang-tools-extra/clang-tidy/modernize/
H A DDeprecatedHeadersCheck.cpp69 return SM.isBeforeInTranslationUnit(ExternCBlockBegin, Marker.DiagLoc) && in VisitLinkageSpecDecl()
70 SM.isBeforeInTranslationUnit(Marker.DiagLoc, ExternCBlockEnd); in VisitLinkageSpecDecl()
120 diag(Marker.DiagLoc, in check()
125 diag(Marker.DiagLoc, "inclusion of deprecated C++ header " in check()
202 SourceLocation DiagLoc = FilenameRange.getBegin(); in InclusionDirective() local
206 FilenameRange.getAsRange(), DiagLoc}); in InclusionDirective()
210 SourceRange{HashLoc, FilenameRange.getEnd()}, DiagLoc}); in InclusionDirective()
H A DDeprecatedHeadersCheck.h52 SourceLocation DiagLoc; member
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/
H A DNoLintDirectiveHandler.cpp231 bool diagHasNoLint(StringRef DiagName, SourceLocation DiagLoc,
259 SourceLocation DiagLoc = Diag.getLocation(); in diagHasNoLintInMacro() local
260 if (DiagLoc.isInvalid()) in diagHasNoLintInMacro()
264 if (diagHasNoLint(DiagName, DiagLoc, SrcMgr, NoLintErrors, AllowIO, in diagHasNoLintInMacro()
267 if (!DiagLoc.isMacroID()) in diagHasNoLintInMacro()
269 DiagLoc = SrcMgr.getImmediateExpansionRange(DiagLoc).getBegin(); in diagHasNoLintInMacro()
319 StringRef DiagName, SourceLocation DiagLoc, const SourceManager &SrcMgr, in diagHasNoLint() argument
325 std::tie(File, Pos) = SrcMgr.getDecomposedSpellingLoc(DiagLoc); in diagHasNoLint()
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/bugprone/
H A DSuspiciousIncludeCheck.cpp81 SourceLocation DiagLoc = FilenameRange.getBegin().getLocWithOffset(1); in InclusionDirective() local
88 Check.diag(DiagLoc, "suspicious #%0 of file with '%1' extension") in InclusionDirective()
97 PP->LookupFile(DiagLoc, GuessedFileName, IsAngled, nullptr, nullptr, in InclusionDirective()
100 Check.diag(DiagLoc, "did you mean to include '%0'?", DiagnosticIDs::Note) in InclusionDirective()
/llvm-project-15.0.7/clang/lib/Lex/
H A DPragma.cpp1239 SourceLocation DiagLoc = DiagToken.getLocation(); in HandlePragma() local
1250 if (!PP.getDiagnostics().popMappings(DiagLoc)) in HandlePragma()
1253 Callbacks->PragmaDiagnosticPop(DiagLoc, Namespace); in HandlePragma()
1256 PP.getDiagnostics().pushMappings(DiagLoc); in HandlePragma()
1334 SourceLocation DiagLoc = Tok.getLocation(); in HandlePragma() local
1361 PP.getDiagnostics().pushMappings(DiagLoc); in HandlePragma()
1363 Callbacks->PragmaWarningPush(DiagLoc, Level); in HandlePragma()
1367 if (!PP.getDiagnostics().popMappings(DiagLoc)) in HandlePragma()
1370 Callbacks->PragmaWarningPop(DiagLoc); in HandlePragma()
1481 SourceLocation DiagLoc = Tok.getLocation(); in HandlePragma() local
[all …]
/llvm-project-15.0.7/clang-tools-extra/clangd/
H A DDiagnostics.cpp126 SourceLocation DiagLoc, Range &R) { in getMainFileRange() argument
172 for (auto IncludeLocation = GetIncludeLoc(SM.getExpansionLoc(DiagLoc)); in getMainFileRange()
190 bool tryMoveToMainFile(Diag &D, FullSourceLoc DiagLoc) { in tryMoveToMainFile() argument
191 const SourceManager &SM = DiagLoc.getManager(); in tryMoveToMainFile()
192 DiagLoc = DiagLoc.getExpansionLoc(); in tryMoveToMainFile()
194 const char *Prefix = getMainFileRange(D, SM, DiagLoc, R); in tryMoveToMainFile()
199 auto FE = *SM.getFileEntryRefForID(SM.getFileID(DiagLoc)); in tryMoveToMainFile()
/llvm-project-15.0.7/clang/lib/Sema/
H A DSemaConcept.cpp465 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
470 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
484 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
489 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
530 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
534 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
552 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
557 S.Diag(SubstDiag->DiagLoc, in diagnoseUnsatisfiedRequirement()
H A DJumpDiagnostics.cpp94 void CheckJump(Stmt *From, Stmt *To, SourceLocation DiagLoc,
919 void JumpScopeChecker::CheckJump(Stmt *From, Stmt *To, SourceLocation DiagLoc, in CheckJump() argument
971 S.Diag(DiagLoc, JumpDiagWarning); in CheckJump()
980 S.Diag(DiagLoc, JumpDiagError); in CheckJump()
986 S.Diag(DiagLoc, JumpDiagCXX98Compat); in CheckJump()
H A DSemaInit.cpp7616 SourceLocation DiagLoc = DiagRange.getBegin(); in checkInitializerLifetime() local
7657 if (IsGslPtrInitWithGslTempOwner && DiagLoc.isValid()) { in checkInitializerLifetime()
7678 Diag(DiagLoc, diag::warn_unsupported_lifetime_extension) in checkInitializerLifetime()
7689 Diag(DiagLoc, diag::warn_dangling_variable) in checkInitializerLifetime()
7706 Diag(DiagLoc, diag::warn_dangling_lifetime_pointer_member) in checkInitializerLifetime()
7714 Diag(DiagLoc, shouldLifetimeExtendThroughPath(Path) != in checkInitializerLifetime()
7776 Diag(DiagLoc, RK == RK_ReferenceBinding in checkInitializerLifetime()
7793 Diag(DiagLoc, diag::warn_ret_stack_addr_ref) in checkInitializerLifetime()
7797 Diag(DiagLoc, diag::err_ret_local_block) << DiagRange; in checkInitializerLifetime()
7803 Diag(DiagLoc, diag::warn_ret_addr_label) << DiagRange; in checkInitializerLifetime()
[all …]
H A DSemaExprCXX.cpp1249 SourceLocation DiagLoc = LSI->IntroducerRange.getEnd(); in buildLambdaThisCaptureFixit() local
1255 Sema.Diag(DiagLoc, diag::note_lambda_this_capture_fixit) in buildLambdaThisCaptureFixit()
1257 DiagLoc, LSI->NumExplicitCaptures > 0 ? ", this" : "this"); in buildLambdaThisCaptureFixit()
6410 SourceRange DiagLoc = in CXXCheckConditionalOperands() local
6413 Diag(DiagLoc.getBegin(), diag::err_conditional_vector_has_void) in CXXCheckConditionalOperands()
6414 << DiagLoc << IsThrow; in CXXCheckConditionalOperands()
H A DSemaChecking.cpp11298 SourceLocation DiagLoc = SizeArg->getExprLoc(); in CheckMemaccessSize() local
11305 S.Diag(DiagLoc, diag::warn_suspicious_bzero_size); in CheckMemaccessSize()
11306 S.Diag(DiagLoc, diag::note_suspicious_bzero_size_silence); in CheckMemaccessSize()
11308 S.Diag(DiagLoc, diag::warn_suspicious_sizeof_memset) << 0; in CheckMemaccessSize()
11309 S.Diag(DiagLoc, diag::note_suspicious_sizeof_memset_silence) << 0; in CheckMemaccessSize()
11320 SourceLocation DiagLoc = Call->getArg(1)->getExprLoc(); in CheckMemaccessSize() local
11321 S.Diag(DiagLoc, diag::warn_suspicious_sizeof_memset) << 1; in CheckMemaccessSize()
11322 S.Diag(DiagLoc, diag::note_suspicious_sizeof_memset_silence) << 1; in CheckMemaccessSize()
H A DSemaType.cpp5189 SourceLocation DiagLoc, FixitLoc; in GetFullTypeForDeclarator() local
5191 DiagLoc = TInfo->getTypeLoc().getBeginLoc(); in GetFullTypeForDeclarator()
5194 DiagLoc = D.getDeclSpec().getTypeSpecTypeLoc(); in GetFullTypeForDeclarator()
5197 S.Diag(DiagLoc, diag::err_object_cannot_be_passed_returned_by_value) in GetFullTypeForDeclarator()
H A DSemaTemplate.cpp6337 SourceLocation DiagLoc = Arg->getExprLoc(); in isNullPointerValueTemplateArgument() local
6344 DiagLoc = Notes[0].first; in isNullPointerValueTemplateArgument()
6348 S.Diag(DiagLoc, diag::err_template_arg_not_address_constant) in isNullPointerValueTemplateArgument()
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/readability/
H A DNamespaceCommentCheck.cpp193 SourceLocation DiagLoc = in check() local
198 diag(DiagLoc, Message) << NamespaceNameForDiag in check()
/llvm-project-15.0.7/clang/tools/libclang/
H A DCXLoadedDiagnostic.h81 Location DiagLoc; variable
H A DCXLoadedDiagnostic.cpp102 return makeLocation(&DiagLoc); in getLocation()
380 if (std::error_code EC = readLocation(Location, D.DiagLoc)) in visitDiagnosticRecord()
/llvm-project-15.0.7/clang/lib/AST/
H A DCommentSema.cpp543 SourceLocation DiagLoc; in checkBlockCommandEmptyParagraph() local
545 DiagLoc = Command->getArgRange(Command->getNumArgs() - 1).getEnd(); in checkBlockCommandEmptyParagraph()
546 if (!DiagLoc.isValid()) in checkBlockCommandEmptyParagraph()
547 DiagLoc = Command->getCommandNameRange(Traits).getEnd(); in checkBlockCommandEmptyParagraph()
548 Diag(DiagLoc, diag::warn_doc_block_command_empty_paragraph) in checkBlockCommandEmptyParagraph()
H A DExprConstant.cpp2116 EvalInfo &Info, SourceLocation DiagLoc,
2349 EvalInfo &Info, SourceLocation DiagLoc, in CheckEvaluationResult() argument
2355 Info.FFDiag(DiagLoc, diag::note_constexpr_uninitialized) in CheckEvaluationResult()
2373 if (!CheckEvaluationResult(CERK, Info, DiagLoc, EltTy, in CheckEvaluationResult()
2380 return CheckEvaluationResult(CERK, Info, DiagLoc, EltTy, in CheckEvaluationResult()
2386 CERK, Info, DiagLoc, Value.getUnionField()->getType(), in CheckEvaluationResult()
2395 if (!CheckEvaluationResult(CERK, Info, DiagLoc, BS.getType(), in CheckEvaluationResult()
2406 if (!CheckEvaluationResult(CERK, Info, DiagLoc, I->getType(), in CheckEvaluationResult()
2417 return CheckLValueConstantExpression(Info, DiagLoc, Type, LVal, Kind, in CheckEvaluationResult()
2441 Info, DiagLoc, Type, Value, Kind, in CheckConstantExpression()
[all …]
/llvm-project-15.0.7/clang/unittests/Basic/
H A DSarifTest.cpp274 CharSourceRange DiagLoc{getFakeCharSourceRange(MainFileID, {2, 5}, {2, 8})}; in TEST_F() local
313 .setLocations({DiagLoc}) in TEST_F()
/llvm-project-15.0.7/clang/lib/Parse/
H A DParseExprCXX.cpp1099 SourceLocation DiagLoc; in ParseLambdaIntroducer() local
1102 DiagLoc = Loc; in ParseLambdaIntroducer()
1106 assert(DiagLoc.isValid() && "no location for diagnostic"); in ParseLambdaIntroducer()
1110 auto &&D = Diag(DiagLoc, DiagID); in ParseLambdaIntroducer()
2657 SourceLocation DiagLoc; in ParseUnqualifiedIdOperator() local
2669 DiagLoc = Tok.getLocation(); in ParseUnqualifiedIdOperator()
2706 DiagLoc = TokLocs.front(); in ParseUnqualifiedIdOperator()
2716 Diag(DiagLoc, DiagId) << FixItHint::CreateReplacement( in ParseUnqualifiedIdOperator()
/llvm-project-15.0.7/clang/include/clang/AST/
H A DExprConcepts.h168 SourceLocation DiagLoc; member
/llvm-project-15.0.7/llvm/lib/MC/MCParser/
H A DAsmParser.cpp2452 SMLoc DiagLoc = Diag.getLoc(); in DiagHandler() local
2453 unsigned DiagBuf = DiagSrcMgr.FindBufferContainingLoc(DiagLoc); in DiagHandler()
2459 unsigned DiagCurBuffer = DiagSrcMgr.FindBufferContainingLoc(DiagLoc); in DiagHandler()
2482 int DiagLocLineNo = DiagSrcMgr.FindLineNumber(DiagLoc, DiagBuf); in DiagHandler()
H A DMasmParser.cpp2795 SMLoc DiagLoc = Diag.getLoc(); in DiagHandler() local
2796 unsigned DiagBuf = DiagSrcMgr.FindBufferContainingLoc(DiagLoc); in DiagHandler()
2802 unsigned DiagCurBuffer = DiagSrcMgr.FindBufferContainingLoc(DiagLoc); in DiagHandler()
2826 int DiagLocLineNo = DiagSrcMgr.FindLineNumber(DiagLoc, DiagBuf); in DiagHandler()
/llvm-project-15.0.7/clang/tools/c-index-test/
H A Dc-index-test.c4709 CXSourceLocation DiagLoc; in printDiagnosticSet() local
4717 DiagLoc = clang_getDiagnosticLocation(D); in printDiagnosticSet()
4718 clang_getExpansionLocation(DiagLoc, &File, &line, &column, &offset); in printDiagnosticSet()
/llvm-project-15.0.7/clang/lib/Serialization/
H A DASTReaderStmt.cpp815 SourceLocation DiagLoc = Record.readSourceLocation(); in readSubstitutionDiagnostic() local
818 concepts::Requirement::SubstitutionDiagnostic{SubstitutedEntity, DiagLoc, in readSubstitutionDiagnostic()

12