https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/92401
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand closed https://github.com/llvm/llvm-project/pull/91616
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/91616
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -476,7 +476,7 @@ runTypeErasedDataflowAnalysis(
PrettyStackTraceAnalysis CrashInfo(ACFG, "runTypeErasedDataflowAnalysis");
std::optional MaybeStartingEnv;
- if (InitEnv.callStackSize() == 1) {
+ if (InitEnv.callStackSize() == 0) {
ymand wrote:
https://github.com/ymand approved this pull request.
Nice!
https://github.com/llvm/llvm-project/pull/91616
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -718,29 +730,46 @@ class Environment {
void pushCallInternal(const FunctionDecl *FuncDecl,
ArrayRef Args);
+ // FIXME: Add support for resetting globals after function calls to enable
+ // the implementation of sound analyses.
+
/// Assigns
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/91616
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
ymand wrote:
> I agree with the usefulness of storing the initial target separately,
> reducing checks and branching based on whether the current target is a `Stmt`
> or `Function`. Since I was touching everywhere `CallStack` was used anyway, I
> went ahead with not pushing the starting
https://github.com/ymand commented:
I think we can do this without resorting to a pointer union and templating of
the initialization functions, but it will take a little refactoring.
First, notice that `stmt` doesn't make sense for the CallStack. The call stack
serves two purposes -- to avoid
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/91455
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/91316
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -209,6 +221,9 @@ class DataflowAnalysisContext {
using DenseMapInfo::isEqual;
};
+ DataflowAnalysisContext(Solver , std::unique_ptr OwnedSolver,
ymand wrote:
Please add comments either here or on the fields relating S and OwnedSolver.
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/91316
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/91316
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/91320
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/75170
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/91172
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/90898
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/90112
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/89596
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand closed https://github.com/llvm/llvm-project/pull/89444
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/89444
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -401,6 +401,29 @@ class ResultObjectVisitor : public
RecursiveASTVisitor {
return true;
}
+ void
+ PropagateResultObjectToRecordInitList(const RecordInitListHelper ,
+RecordStorageLocation *Loc) {
+for (auto [Base, Init]
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/89235
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/89235
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -5243,6 +5243,67 @@ TEST(TransferTest, BinaryOperatorComma) {
});
}
+TEST(TransferTest, ConditionalOperatorValue) {
+ std::string Code = R"(
+void target(bool Cond, bool B1, bool B2) {
+ bool JoinSame = Cond ? B1 : B1;
+ bool JoinDifferent = Cond ? B1
@@ -657,17 +658,22 @@ class TransferVisitor : public
ConstStmtVisitor {
}
void VisitConditionalOperator(const ConditionalOperator *S) {
-// FIXME: Revisit this once flow conditions are added to the framework. For
-// `a = b ? c : d` we can add `b => a == c && !b
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/89213
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/89213
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/88727
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
Thanks!
https://github.com/llvm/llvm-project/pull/88865
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand closed https://github.com/llvm/llvm-project/pull/88754
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/88875
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/88872
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
ymand wrote:
Clearly, this is a matter of taste, so I would defer to your opinion, since you
are the primary maintainer of this code. But, personally, I prefer this style
since it makes clear that the body of the function is a single case analysis,
which is not obvious from the series of if
https://github.com/ymand approved this pull request.
Thanks!
https://github.com/llvm/llvm-project/pull/88754
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -508,6 +508,11 @@ class ResultObjectVisitor : public
RecursiveASTVisitor {
isa(E)) {
return;
}
+if (auto *Op = dyn_cast(E);
ymand wrote:
I guess the `isa` calls were what we really jumped out since they amount to N
calls and tests
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/88726
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -508,6 +508,11 @@ class ResultObjectVisitor : public
RecursiveASTVisitor {
isa(E)) {
return;
}
+if (auto *Op = dyn_cast(E);
ymand wrote:
aside: Might lines 506 through 553 be better expressed as a switch on
`E->getStmtClass()`?
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/88726
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -62,6 +62,52 @@ FieldSet getObjectFields(QualType Type);
bool containsSameFields(const FieldSet ,
const RecordStorageLocation::FieldToLoc );
+/// Returns the fields of a `RecordDecl` that are initialized by an
+/// `InitListExpr`, in the order in
https://github.com/ymand approved this pull request.
Thanks!
https://github.com/llvm/llvm-project/pull/88534
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -62,6 +62,52 @@ FieldSet getObjectFields(QualType Type);
bool containsSameFields(const FieldSet ,
const RecordStorageLocation::FieldToLoc );
+/// Returns the fields of a `RecordDecl` that are initialized by an
+/// `InitListExpr`, in the order in
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/88534
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/88358
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/88316
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -510,6 +519,26 @@ int c = M3(3);
Visitor.runOver(Code.code());
}
+TEST(SourceCodeTest, InnerNestedTemplate) {
ymand wrote:
Add a test case that covers the case of the split being in the BeginToken?
https://github.com/llvm/llvm-project/pull/87673
https://github.com/ymand approved this pull request.
Nice work - really subtle! I'd been wondering how clang handles this issue (of
relexing returning the wrong token because it lacked context).
https://github.com/llvm/llvm-project/pull/87673
___
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/87673
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
ymand wrote:
I also fixed up the other tests to use `getValue/LocForDecl` to be consistent.
https://github.com/llvm/llvm-project/pull/87233
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/87233
>From d8d875271bd47b71701143afb06ea654546e2b7c Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Mon, 1 Apr 2024 12:13:39 +
Subject: [PATCH 1/4] [clang][dataflow] Refactor `widen` API to be explicit
ymand wrote:
Martin, I've addressed all of your comments. PTAL.
https://github.com/llvm/llvm-project/pull/87233
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -975,6 +994,35 @@ TEST_F(WideningTest,
DistinctValuesWithSamePropertiesAreEquivalent) {
});
}
+TEST_F(WideningTest, DistinctValuesWithDifferentPropertiesWidenedToTop) {
+ std::string Code = R"(
+void target(bool Cond) {
+ int *Foo;
+ int i = 0;
+
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/87233
>From d8d875271bd47b71701143afb06ea654546e2b7c Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Mon, 1 Apr 2024 12:13:39 +
Subject: [PATCH 1/3] [clang][dataflow] Refactor `widen` API to be explicit
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/87233
>From d8d875271bd47b71701143afb06ea654546e2b7c Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Mon, 1 Apr 2024 12:13:39 +
Subject: [PATCH 1/2] [clang][dataflow] Refactor `widen` API to be explicit
@@ -975,6 +994,35 @@ TEST_F(WideningTest,
DistinctValuesWithSamePropertiesAreEquivalent) {
});
}
+TEST_F(WideningTest, DistinctValuesWithDifferentPropertiesWidenedToTop) {
+ std::string Code = R"(
+void target(bool Cond) {
+ int *Foo;
+ int i = 0;
+
@@ -975,6 +994,35 @@ TEST_F(WideningTest,
DistinctValuesWithSamePropertiesAreEquivalent) {
});
}
+TEST_F(WideningTest, DistinctValuesWithDifferentPropertiesWidenedToTop) {
+ std::string Code = R"(
+void target(bool Cond) {
+ int *Foo;
+ int i = 0;
+
@@ -805,6 +805,25 @@ class NullPointerAnalysis final
else
JoinedVal.setProperty("is_null", JoinedEnv.makeTopBoolValue());
}
+
+ std::optional widen(QualType Type, Value ,
+ const Environment , Value ,
+
@@ -122,17 +135,19 @@ class Environment {
///
/// `Prev` and `Current` must be assigned to the same storage location in
/// `PrevEnv` and `CurrentEnv`, respectively.
-virtual Value *widen(QualType Type, Value , const Environment
,
-
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/87233
>From d8d875271bd47b71701143afb06ea654546e2b7c Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Mon, 1 Apr 2024 12:13:39 +
Subject: [PATCH] [clang][dataflow] Refactor `widen` API to be explicit about
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/87233
>From b7f63ed7ca3c503f55eccc215f0a66368e2c5e5e Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Mon, 1 Apr 2024 12:13:39 +
Subject: [PATCH] [clang][dataflow] Refactor `widen` API to be explicit about
https://github.com/ymand created https://github.com/llvm/llvm-project/pull/87233
The previous API relied on pointer equality of inputs and outputs to signal
whether a change occured. This was too subtle and led to bugs in practice. It
was also very limiting: the override could not return an
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/86942
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -744,6 +744,35 @@ RecordStorageLocation *getBaseObjectLocation(const
MemberExpr ,
std::vector
getFieldsForInitListExpr(const InitListExpr *InitList);
+/// Helper class for initialization of a record with an `InitListExpr`.
+/// `InitListExpr::inits()` contains the
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/86675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/86675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
Thanks!
https://github.com/llvm/llvm-project/pull/86479
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -50,29 +50,206 @@ const Environment *StmtToEnvMap::getEnvironment(const Stmt
) const {
return >Env;
}
-static BoolValue (const Expr , const Expr ,
- Environment ) {
- Value *LHSValue = Env.getValue(LHS);
- Value *RHSValue =
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/82950
>From 33f753d99bbb477ad37614d29658e964aa590a80 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 23 Feb 2024 20:15:36 +
Subject: [PATCH 1/3] [clang][dataflow] Factor out built-in boolean model into
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/82950
>From 33f753d99bbb477ad37614d29658e964aa590a80 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 23 Feb 2024 20:15:36 +
Subject: [PATCH 1/3] [clang][dataflow] Factor out built-in boolean model into
ymand wrote:
Martin, I've thoroughly updated the refactoring, exactly as you suggested --
all of the interesting differences are actually just in how we handle the
logical operations, so most of the changes are now in DataflowEnvironment.cpp.
I've left the factoring in Transfer because we
@@ -1059,9 +1066,16 @@ void Environment::assume(const Formula ) {
DACtx->addFlowConditionConstraint(FlowConditionToken, F);
}
+#if 0
bool Environment::proves(const Formula ) const {
return DACtx->flowConditionImplies(FlowConditionToken, F);
}
+#else
+bool
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/82950
>From 33f753d99bbb477ad37614d29658e964aa590a80 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 23 Feb 2024 20:15:36 +
Subject: [PATCH 1/3] [clang][dataflow] Factor out built-in boolean model into
ymand wrote:
Looks good, but per LLVM style guidelines, should we go ahead and replace the
`auto` as well?
https://github.com/llvm/llvm-project/pull/85962
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
ymand wrote:
Just a note: I've siginfiicantly simplified the code that you're modifying in
this PR (https://github.com/llvm/llvm-project/pull/84499), so expect some merge
conflicts next time you pull from main.
https://github.com/llvm/llvm-project/pull/80989
https://github.com/ymand closed https://github.com/llvm/llvm-project/pull/84499
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/84499
>From 02381f2dbdcc569889ae55a2ca5d8698f74626d8 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 8 Mar 2024 15:19:14 +
Subject: [PATCH 1/2] [clang][dataflow] Refactor processing of terminator
@@ -337,26 +274,33 @@ computeBlockInputState(const CFGBlock ,
AnalysisContext ) {
AC.BlockStates[Pred->getBlockID()];
if (!MaybePredState)
continue;
-
-if (AC.Analysis.builtinOptions()) {
- if (const Stmt *PredTerminatorStmt =
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/84499
>From 3b20e1823753ab46e3e259d3d8c727dea91ce1d4 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 8 Mar 2024 15:19:14 +
Subject: [PATCH 1/2] [clang][dataflow] Refactor processing of terminator
@@ -129,19 +215,19 @@ auto inPlaceClass() {
auto isOptionalNulloptConstructor() {
return cxxConstructExpr(
- hasOptionalType(),
+ hasOptionalOrDerivedType(),
ymand wrote:
Here and below -- now that this matcher is more expensive, please move
@@ -64,39 +64,117 @@ static bool hasOptionalClassName(const CXXRecordDecl ) {
return false;
}
+static const CXXRecordDecl *getOptionalBaseClass(const CXXRecordDecl *RD) {
+ if (RD == nullptr)
+return nullptr;
+ if (hasOptionalClassName(*RD))
+return RD;
+
+ if
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/84138
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -119,20 +119,28 @@ QualType getPublicType(const Expr *E) {
return Ty;
}
- QualType Ty = getPublicType(Cast->getSubExpr());
-
- // Is `Ty` the type of `*this`? In this special case, we can upcast to the
- // base class even if the base is non-public.
- bool
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/84138
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
thanks!
https://github.com/llvm/llvm-project/pull/85623
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/85640
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
https://github.com/llvm/llvm-project/pull/85072
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand approved this pull request.
modulo Gabor's comments.
https://github.com/llvm/llvm-project/pull/85064
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -64,39 +64,117 @@ static bool hasOptionalClassName(const CXXRecordDecl ) {
return false;
}
+static const CXXRecordDecl *getOptionalBaseClass(const CXXRecordDecl *RD) {
+ if (RD == nullptr)
+return nullptr;
+ if (hasOptionalClassName(*RD))
+return RD;
+
+ if
@@ -129,19 +207,19 @@ auto inPlaceClass() {
auto isOptionalNulloptConstructor() {
return cxxConstructExpr(
- hasOptionalType(),
+ hasOptionalOrDerivedType(),
ymand wrote:
Here and below: Why admit a derived class here? I would think that we don't
@@ -64,39 +64,117 @@ static bool hasOptionalClassName(const CXXRecordDecl ) {
return false;
}
+static const CXXRecordDecl *getOptionalBaseClass(const CXXRecordDecl *RD) {
+ if (RD == nullptr)
+return nullptr;
+ if (hasOptionalClassName(*RD))
+return RD;
+
+ if
@@ -64,39 +64,117 @@ static bool hasOptionalClassName(const CXXRecordDecl ) {
return false;
}
+static const CXXRecordDecl *getOptionalBaseClass(const CXXRecordDecl *RD) {
+ if (RD == nullptr)
+return nullptr;
+ if (hasOptionalClassName(*RD))
+return RD;
+
+ if
@@ -64,39 +64,117 @@ static bool hasOptionalClassName(const CXXRecordDecl ) {
return false;
}
+static const CXXRecordDecl *getOptionalBaseClass(const CXXRecordDecl *RD) {
+ if (RD == nullptr)
+return nullptr;
+ if (hasOptionalClassName(*RD))
+return RD;
+
+ if
https://github.com/ymand commented:
One high level question: is there a simpler path by which we avoid crashing on
derived types but also don't support them? It seems like there is a lot of
complexity required in getting this just right. Is it worth it (both in the
code itself and in terms of
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/84138
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/82950
>From 3b20e1823753ab46e3e259d3d8c727dea91ce1d4 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 8 Mar 2024 15:19:14 +
Subject: [PATCH 1/3] [clang][dataflow] Refactor processing of terminator
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/84499
>From 3b20e1823753ab46e3e259d3d8c727dea91ce1d4 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 8 Mar 2024 15:19:14 +
Subject: [PATCH] [clang][dataflow] Refactor processing of terminator element
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/84499
>From d1bedf3a9b1d0d4c2fbfc10509797b39eef3d592 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 8 Mar 2024 15:19:14 +
Subject: [PATCH] [clang][dataflow] Refactor processing of terminator element
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/84499
>From b7887543320f8727545a7ce8e6d9e02b77604472 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 8 Mar 2024 15:19:14 +
Subject: [PATCH] [clang][dataflow] Refactor processing of terminator element
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/84499
>From 81945389b60e95019ff916d356127119183e8198 Mon Sep 17 00:00:00 2001
From: Yitzhak Mandelbaum
Date: Fri, 8 Mar 2024 15:19:14 +
Subject: [PATCH] [clang][dataflow] Refactor processing of terminator element
1 - 100 of 572 matches
Mail list logo