clang 20.0.0git
|
#include "clang/Analysis/PathDiagnostic.h"
Public Member Functions | |
~PathDiagnosticCallPiece () override | |
const Decl * | getCaller () const |
const Decl * | getCallee () const |
void | setCallee (const CallEnter &CE, const SourceManager &SM) |
bool | hasCallStackMessage () |
void | setCallStackMessage (StringRef st) |
PathDiagnosticLocation | getLocation () const override |
std::shared_ptr< PathDiagnosticEventPiece > | getCallEnterEvent () const |
std::shared_ptr< PathDiagnosticEventPiece > | getCallEnterWithinCallerEvent () const |
std::shared_ptr< PathDiagnosticEventPiece > | getCallExitEvent () const |
void | flattenLocations () override |
void | dump () const override |
void | Profile (llvm::FoldingSetNodeID &ID) const override |
Public Member Functions inherited from clang::ento::PathDiagnosticPiece | |
PathDiagnosticPiece ()=delete | |
PathDiagnosticPiece (const PathDiagnosticPiece &)=delete | |
PathDiagnosticPiece & | operator= (const PathDiagnosticPiece &)=delete |
virtual | ~PathDiagnosticPiece () |
StringRef | getString () const |
void | setTag (const char *tag) |
Tag this PathDiagnosticPiece with the given C-string. | |
const void * | getTag () const |
Return the opaque tag (if any) on the PathDiagnosticPiece. | |
StringRef | getTagStr () const |
Return the string representation of the tag. | |
DisplayHint | getDisplayHint () const |
getDisplayHint - Return a hint indicating where the diagnostic should be displayed by the PathDiagnosticConsumer. | |
virtual PathDiagnosticLocation | getLocation () const =0 |
virtual void | flattenLocations ()=0 |
Kind | getKind () const |
void | addRange (SourceRange R) |
void | addRange (SourceLocation B, SourceLocation E) |
void | addFixit (FixItHint F) |
ArrayRef< SourceRange > | getRanges () const |
Return the SourceRanges associated with this PathDiagnosticPiece. | |
ArrayRef< FixItHint > | getFixits () const |
Return the fix-it hints associated with this PathDiagnosticPiece. | |
virtual void | Profile (llvm::FoldingSetNodeID &ID) const |
void | setAsLastInMainSourceFile () |
bool | isLastInMainSourceFile () const |
virtual void | dump () const =0 |
Static Public Member Functions | |
static std::shared_ptr< PathDiagnosticCallPiece > | construct (const CallExitEnd &CE, const SourceManager &SM) |
static PathDiagnosticCallPiece * | construct (PathPieces &pieces, const Decl *caller) |
static bool | classof (const PathDiagnosticPiece *P) |
Public Attributes | |
PathDiagnosticLocation | callEnter |
PathDiagnosticLocation | callEnterWithin |
PathDiagnosticLocation | callReturn |
PathPieces | path |
Additional Inherited Members | |
Public Types inherited from clang::ento::PathDiagnosticPiece | |
enum | Kind { ControlFlow , Event , Macro , Call , Note , PopUp } |
enum | DisplayHint { Above , Below } |
Protected Member Functions inherited from clang::ento::PathDiagnosticPiece | |
PathDiagnosticPiece (StringRef s, Kind k, DisplayHint hint=Below) | |
PathDiagnosticPiece (Kind k, DisplayHint hint=Below) | |
Definition at line 562 of file PathDiagnostic.h.
|
overridedefault |
|
inlinestatic |
Definition at line 627 of file PathDiagnostic.h.
References clang::ento::PathDiagnosticPiece::Call, and P.
|
static |
Definition at line 849 of file PathDiagnostic.cpp.
References clang::CallExitEnd::getCalleeContext(), clang::LocationContext::getDecl(), clang::ProgramPoint::getLocationContext(), getLocationForCaller(), and SM.
|
static |
Definition at line 860 of file PathDiagnostic.cpp.
References clang::C.
|
overridevirtual |
Implements clang::ento::PathDiagnosticPiece.
Definition at line 1161 of file PathDiagnostic.cpp.
|
inlineoverridevirtual |
Implements clang::ento::PathDiagnosticPiece.
Definition at line 609 of file PathDiagnostic.h.
References callEnter, callReturn, clang::ento::PathDiagnosticLocation::flatten(), and path.
|
inline |
Definition at line 596 of file PathDiagnostic.h.
Referenced by resetDiagnosticLocationToMainFile().
std::shared_ptr< PathDiagnosticEventPiece > PathDiagnosticCallPiece::getCallEnterEvent | ( | ) | const |
Definition at line 1004 of file PathDiagnostic.cpp.
References describeCodeDecl().
std::shared_ptr< PathDiagnosticEventPiece > PathDiagnosticCallPiece::getCallEnterWithinCallerEvent | ( | ) | const |
Definition at line 1023 of file PathDiagnostic.cpp.
References describeCodeDecl().
|
inline |
Definition at line 594 of file PathDiagnostic.h.
Referenced by resetDiagnosticLocationToMainFile().
std::shared_ptr< PathDiagnosticEventPiece > PathDiagnosticCallPiece::getCallExitEvent | ( | ) | const |
Definition at line 1042 of file PathDiagnostic.cpp.
References describeCodeDecl().
|
inlineoverridevirtual |
Implements clang::ento::PathDiagnosticPiece.
Definition at line 602 of file PathDiagnostic.h.
References callEnter.
Referenced by resetDiagnosticLocationToMainFile().
|
inline |
Definition at line 599 of file PathDiagnostic.h.
|
overridevirtual |
Reimplemented from clang::ento::PathDiagnosticPiece.
Definition at line 1105 of file PathDiagnostic.cpp.
References clang::ento::PathDiagnosticPiece::Profile().
void PathDiagnosticCallPiece::setCallee | ( | const CallEnter & | CE, |
const SourceManager & | SM | ||
) |
Definition at line 870 of file PathDiagnostic.cpp.
References clang::ento::PathDiagnosticLocation::createBegin(), clang::LocationContext::getAnalysisDeclContext(), clang::CallEnter::getCalleeContext(), clang::LocationContext::getDecl(), clang::ProgramPoint::getLocationContext(), getLocationForCaller(), clang::AnalysisDeclContext::isBodyAutosynthesized(), and SM.
|
inline |
Definition at line 600 of file PathDiagnostic.h.
PathDiagnosticLocation clang::ento::PathDiagnosticCallPiece::callEnter |
Definition at line 587 of file PathDiagnostic.h.
Referenced by compareCall(), flattenLocations(), getFirstStackedCallToHeaderFile(), and getLocation().
PathDiagnosticLocation clang::ento::PathDiagnosticCallPiece::callEnterWithin |
Definition at line 588 of file PathDiagnostic.h.
Referenced by compareCall(), and getFirstStackedCallToHeaderFile().
PathDiagnosticLocation clang::ento::PathDiagnosticCallPiece::callReturn |
Definition at line 589 of file PathDiagnostic.h.
Referenced by compareCall(), and flattenLocations().
PathPieces clang::ento::PathDiagnosticCallPiece::path |
Definition at line 590 of file PathDiagnostic.h.
Referenced by compareCall(), flattenLocations(), and getFirstStackedCallToHeaderFile().