File tree Expand file tree Collapse file tree 2 files changed +25
-3
lines changed
include/clang/Analysis/Analyses Expand file tree Collapse file tree 2 files changed +25
-3
lines changed Original file line number Diff line number Diff line change 1+ // ===- LifetimeSafety.h - C++ Lifetime Safety Analysis -*----------- C++-*-===//
2+ //
3+ // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ // See https://llvm.org/LICENSE.txt for license information.
5+ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ //
7+ // ===----------------------------------------------------------------------===//
8+ //
9+ // This file defines the entry point for a dataflow-based static analysis
10+ // that checks for C++ lifetime violations.
11+ //
12+ // The analysis is based on the concepts of "origins" and "loans" to track
13+ // pointer lifetimes and detect issues like use-after-free and dangling
14+ // pointers. See the RFC for more details:
15+ // https://discourse.llvm.org/t/rfc-intra-procedural-lifetime-analysis-in-clang/86291
16+ //
17+ // ===----------------------------------------------------------------------===//
118#ifndef LLVM_CLANG_ANALYSIS_ANALYSES_LIFETIMESAFETY_H
219#define LLVM_CLANG_ANALYSIS_ANALYSES_LIFETIMESAFETY_H
320#include " clang/AST/DeclBase.h"
Original file line number Diff line number Diff line change 1+ // ===- LifetimeSafety.cpp - C++ Lifetime Safety Analysis -*--------- C++-*-===//
2+ //
3+ // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ // See https://llvm.org/LICENSE.txt for license information.
5+ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ //
7+ // ===----------------------------------------------------------------------===//
18#include " clang/Analysis/Analyses/LifetimeSafety.h"
29#include " clang/AST/Decl.h"
310#include " clang/AST/Expr.h"
411#include " clang/AST/StmtVisitor.h"
512#include " clang/AST/Type.h"
13+ #include " clang/Analysis/Analyses/PostOrderCFGView.h"
614#include " clang/Analysis/AnalysisDeclContext.h"
715#include " clang/Analysis/CFG.h"
8- #include " clang/Analysis/FlowSensitive/DataflowWorklist.h"
916#include " llvm/ADT/FoldingSet.h"
10- #include " llvm/ADT/ImmutableMap.h"
11- #include " llvm/ADT/ImmutableSet.h"
1217#include " llvm/ADT/PointerUnion.h"
1318#include " llvm/ADT/SmallVector.h"
1419#include " llvm/Support/Debug.h"
You can’t perform that action at this time.
0 commit comments