|
clang-tools 22.0.0git
|
#include "RedundantBranchConditionCheck.h"#include "../utils/Aliasing.h"#include "clang/AST/ASTContext.h"#include "clang/ASTMatchers/ASTMatchFinder.h"#include "clang/Analysis/Analyses/ExprMutationAnalyzer.h"#include "clang/Lex/Lexer.h"Go to the source code of this file.
Namespaces | |
| namespace | clang |
| ===– Representation.cpp - ClangDoc Representation --------—*- C++ -*-===// | |
| namespace | clang::tidy |
| namespace | clang::tidy::bugprone |
Functions | |
| static bool | clang::tidy::bugprone::isChangedBefore (const Stmt *S, const Stmt *NextS, const Stmt *PrevS, const VarDecl *Var, ASTContext *Context) |
| Returns whether Var is changed in range (PrevS..NextS). | |
| bool | hasPtrOrReferenceInFunc (const Decl *Func, const ValueDecl *Var) |
Returns whether Var has a pointer or reference in Func. | |
Variables | |
| static const char | clang::tidy::bugprone::CondVarStr [] = "cond_var" |
| static const char | clang::tidy::bugprone::OuterIfStr [] = "outer_if" |
| static const char | clang::tidy::bugprone::InnerIfStr [] = "inner_if" |
| static const char | clang::tidy::bugprone::OuterIfVar1Str [] = "outer_if_var1" |
| static const char | clang::tidy::bugprone::OuterIfVar2Str [] = "outer_if_var2" |
| static const char | clang::tidy::bugprone::InnerIfVar1Str [] = "inner_if_var1" |
| static const char | clang::tidy::bugprone::InnerIfVar2Str [] = "inner_if_var2" |
| static const char | clang::tidy::bugprone::FuncStr [] = "func" |
| bool clang::tidy::utils::hasPtrOrReferenceInFunc | ( | const Decl * | Func, |
| const ValueDecl * | Var ) |
Returns whether Var has a pointer or reference in Func.
Example: void f() { int n; ... int *p = &n; }
For f() and n the function returns true because p is a / pointer to n created in f().
Definition at line 92 of file Aliasing.cpp.