class ExprMutationAnalyzer

Declaration

class ExprMutationAnalyzer { /* full declaration omitted */ };

Description

Analyzes whether any mutative operations are applied to an expression within a given statement.

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:23

Member Variables

private const clang::Stmt& Stm
private clang::ASTContext& Context
private llvm::DenseMap< const FunctionDecl*, std::unique_ptr<FunctionParmMutationAnalyzer>> FuncParmAnalyzer
private clang::ExprMutationAnalyzer::ResultMap Results
private clang::ExprMutationAnalyzer::ResultMap PointeeResults

Method Overview

Methods

ExprMutationAnalyzer(const clang::Stmt& Stm,
                     clang::ASTContext& Context)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:25

Parameters

const clang::Stmt& Stm
clang::ASTContext& Context

const clang::Stmt* findArrayElementMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:64

Parameters

const clang::Expr* Exp

const clang::Stmt* findCastMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:65

Parameters

const clang::Expr* Exp

const clang::Stmt* findDeclMutation(
    ArrayRef<ast_matchers::BoundNodes> Matches)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:56

Parameters

ArrayRef<ast_matchers::BoundNodes> Matches

const clang::Stmt* findDeclPointeeMutation(
    ArrayRef<ast_matchers::BoundNodes> Matches)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:60

Parameters

ArrayRef<ast_matchers::BoundNodes> Matches

const clang::Stmt* findDirectMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:62

Parameters

const clang::Expr* Exp

const clang::Stmt* findExprMutation(
    ArrayRef<ast_matchers::BoundNodes> Matches)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:55

Parameters

ArrayRef<ast_matchers::BoundNodes> Matches

const clang::Stmt* findExprPointeeMutation(
    ArrayRef<ast_matchers::BoundNodes> Matches)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:58

Parameters

ArrayRef<ast_matchers::BoundNodes> Matches

const clang::Stmt* findFunctionArgMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:68

Parameters

const clang::Expr* Exp

const clang::Stmt* findMemberMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:63

Parameters

const clang::Expr* Exp

const clang::Stmt* findMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:30

Parameters

const clang::Expr* Exp

const clang::Stmt* findMutation(
    const clang::Decl* Dec)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:31

Parameters

const clang::Decl* Dec

const clang::Stmt* findMutationMemoized(
    const clang::Expr* Exp,
    llvm::ArrayRef<MutationFinder> Finders,
    clang::ExprMutationAnalyzer::ResultMap&
        MemoizedResults)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:48

Parameters

const clang::Expr* Exp
llvm::ArrayRef<MutationFinder> Finders
clang::ExprMutationAnalyzer::ResultMap& MemoizedResults

const clang::Stmt* findPointeeMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:39

Parameters

const clang::Expr* Exp

const clang::Stmt* findPointeeMutation(
    const clang::Decl* Dec)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:40

Parameters

const clang::Decl* Dec

const clang::Stmt* findRangeLoopMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:66

Parameters

const clang::Expr* Exp

const clang::Stmt* findReferenceMutation(
    const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:67

Parameters

const clang::Expr* Exp

bool isMutated(const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:28

Parameters

const clang::Expr* Exp

bool isMutated(const clang::Decl* Dec)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:29

Parameters

const clang::Decl* Dec

bool isPointeeMutated(const clang::Decl* Dec)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:36

Parameters

const clang::Decl* Dec

bool isPointeeMutated(const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:33

Parameters

const clang::Expr* Exp

bool isUnevaluated(const clang::Expr* Exp)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:53

Parameters

const clang::Expr* Exp

static bool isUnevaluated(
    const clang::Stmt* Smt,
    const clang::Stmt& Stm,
    clang::ASTContext& Context)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:41

Parameters

const clang::Stmt* Smt
const clang::Stmt& Stm
clang::ASTContext& Context

const clang::Stmt* tryEachDeclRef(
    const clang::Decl* Dec,
    clang::ExprMutationAnalyzer::MutationFinder
        Finder)

Declared at: clang/include/clang/Analysis/Analyses/ExprMutationAnalyzer.h:51

Parameters

const clang::Decl* Dec
clang::ExprMutationAnalyzer::MutationFinder Finder