#include "ThrowByValueCatchByReferenceCheck.h"
#include "clang/AST/ASTContext.h"
#include "clang/AST/OperationKinds.h"
#include "clang/ASTMatchers/ASTMatchFinder.h"
usingnamespaceclang::ast_matchers;
namespace clang::tidy::misc {
ThrowByValueCatchByReferenceCheck::ThrowByValueCatchByReferenceCheck(
StringRef Name, ClangTidyContext *Context)
: … { … }
void ThrowByValueCatchByReferenceCheck::registerMatchers(MatchFinder *Finder) { … }
void ThrowByValueCatchByReferenceCheck::storeOptions(
ClangTidyOptions::OptionMap &Opts) { … }
void ThrowByValueCatchByReferenceCheck::check(
const MatchFinder::MatchResult &Result) { … }
bool ThrowByValueCatchByReferenceCheck::isFunctionParameter(
const DeclRefExpr *DeclRefExpr) { … }
bool ThrowByValueCatchByReferenceCheck::isCatchVariable(
const DeclRefExpr *DeclRefExpr) { … }
bool ThrowByValueCatchByReferenceCheck::isFunctionOrCatchVar(
const DeclRefExpr *DeclRefExpr) { … }
void ThrowByValueCatchByReferenceCheck::diagnoseThrowLocations(
const CXXThrowExpr *ThrowExpr) { … }
void ThrowByValueCatchByReferenceCheck::diagnoseCatchLocations(
const CXXCatchStmt *CatchStmt, ASTContext &Context) { … }
}