25class PointerSubChecker
26 :
public Checker< check::PreStmt<BinaryOperator> > {
27 mutable std::unique_ptr<BuiltinBug> BT;
57 if (isa<SymbolicRegion>(BaseLR) || isa<SymbolicRegion>(BaseRR))
64 "Subtraction of two pointers that do not point to "
65 "the same memory chunk may cause incorrect result."));
67 std::make_unique<PathSensitiveBugReport>(*BT, BT->getDescription(), N);
69 C.emitReport(std::move(R));
77bool ento::shouldRegisterPointerSubChecker(
const CheckerManager &mgr) {
A builtin binary operation expression such as "x + y" or "x <= y".
SourceRange getSourceRange() const LLVM_READONLY
SourceLocation tokens are not useful in isolation - they are low level value objects created/interpre...
CHECKER * registerChecker(AT &&... Args)
Used to register checkers.
MemRegion - The root abstract class for all memory regions.
LLVM_ATTRIBUTE_RETURNS_NONNULL const MemRegion * getBaseRegion() const
SVal - This represents a symbolic expression, which can be either an L-value or an R-value.
const MemRegion * getAsRegion() const
@ C
Languages that the frontend can parse and compile.