jcsxky wrote:
> please update release note also
Although `bugprone-unchecked-optional-access` is used to test this issue, root
cause is in `FlowSensitiveAnalysis`. So, I am confused about which file should
be updated about release not. Look forward to your suggestion! Thank you.
https://githu
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/68510
>From 3978a4322ed7f82b52a1978debe8108f00f18acc Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 8 Oct 2023 16:00:29 +0800
Subject: [PATCH] [clang][analysis]Use dyn_cast_or_null instead cast to prevent
crash
---
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/68510
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -599,7 +599,7 @@ void transferAssignment(const CXXOperatorCallExpr *E,
BoolValue &HasValueVal,
LatticeTransferState &State) {
assert(E->getNumArgs() > 0);
- if (auto *Loc = cast(
+ if (auto *Loc = dyn_cast_or_null(
jcsxky wrote:
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/68510
>From 7a8c515c70bb06ae886c8c434d9d3a79a152d115 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 8 Oct 2023 16:00:29 +0800
Subject: [PATCH] [clang][analysis]Use dyn_cast_or_null instead cast to prevent
crash
---
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/68510
>From 38cf358039d81fb3703885db082b64e11760c5fc Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 8 Oct 2023 16:00:29 +0800
Subject: [PATCH] [clang][analysis]Use dyn_cast_or_null instead cast to prevent
crash
---
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/68510
>From 466b612ff055ff7497c9473b38b90bc849370b21 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 8 Oct 2023 16:00:29 +0800
Subject: [PATCH] [clang][analysis]Use dyn_cast_or_null instead cast to prevent
crash
---
jcsxky wrote:
> LGTM, When release notes could be nice
> (clang-tools-extra/doc/ReleaseNotest.rst) with something like: `Improved
> bugprone-unchecked-optional-acces check to not crash during handling of
> optional values` or `to not crash i certain situations` it may also not be so
> necessa
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/68510
>From eb9f8342821048edefaefd038bdd989853ac69a3 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 8 Oct 2023 16:00:29 +0800
Subject: [PATCH] [clang][analysis]Use dyn_cast_or_null instead cast to prevent
crash
---
@@ -180,3 +180,44 @@ void std_forward_rvalue_ref_safe(absl::optional&&
opt) {
std::forward>(opt).value();
}
+
+namespace std {
+
+template
+class optional {
+public:
+ template
+ optional& operator=(const U &u){
jcsxky wrote:
Using `absl::optional`
jcsxky wrote:
> Thanks for this fix! Unfortunately, I wasn't able to repro the crash in
> godbolt: https://godbolt.org/z/s741z5djY. Can you double check that the check
> crashes on that example without your fix?
The test case is different from that in this patch. Use `float` in `optional`.
ht
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/68510
>From 55ca8fa197e469a7c8f57d7a174c07a063eb022e Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 8 Oct 2023 16:00:29 +0800
Subject: [PATCH] [clang][analysis]Use dyn_cast_or_null instead cast to prevent
crash
---
https://github.com/jcsxky deleted
https://github.com/llvm/llvm-project/pull/68510
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
@ymand Could you take a look at this pr?
https://github.com/llvm/llvm-project/pull/68510
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/68510
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky created
https://github.com/llvm/llvm-project/pull/66110:
1.VarDecl should not be ignored.
2.GotoStmt has no children, it should be handle explicitly.
>From ab11dd019685d714a4d697cc021cb313a5b30b95 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Wed, 13 Sep 2023 0
https://github.com/jcsxky review_requested
https://github.com/llvm/llvm-project/pull/66110
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/66110:
>From 3194b8958491331918459e6913e5931cc7528115 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Wed, 13 Sep 2023 00:03:27 +0800
Subject: [PATCH] improve ast comparation 1.VarDecl should not be ignored.
2.Got
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/66110
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/66110:
>From 98a32795dae4587f64c10f91c6ab47f96881ad4b Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Wed, 13 Sep 2023 00:03:27 +0800
Subject: [PATCH] improve ast comparation 1.VarDecl should not be ignored.
2.Got
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/66110:
>From 999017a007b77efc6c4b2e643e82379c7c46ca2b Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Wed, 13 Sep 2023 00:03:27 +0800
Subject: [PATCH] improve ast comparation 1.VarDecl should not be ignored.
2.Got
@@ -1295,6 +1306,21 @@ static bool
IsStructurallyEquivalent(StructuralEquivalenceContext &Context,
return true;
}
+static bool IsStructurallyEquivalent(StructuralEquivalenceContext &Context,
jcsxky wrote:
Thanks for your remind. Storage checking is added a
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/66110
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/80802
>From c19a66ed4eadd5f16b586b349fd578d873902be2 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Tue, 6 Feb 2024 14:06:40 +0800
Subject: [PATCH 1/2] [Clang][Sema] fix crash in codegen stage when an lambda
expression d
jcsxky wrote:
> @jcsxky Do you have more test cases other than the one from #76674? I wonder
> what'll happen if constraint checking is involved.
Do you mean `concept`? If yes, I will have a try.
https://github.com/llvm/llvm-project/pull/80802
___
cf
https://github.com/jcsxky created
https://github.com/llvm/llvm-project/pull/102554
Skip adding template instantiation arguments when the declaration is a nested
class template when instantiating constraint expression.
attempt to fix https://github.com/llvm/llvm-project/issues/102320
>From 0080
jcsxky wrote:
> I'm sorry but this approach doesn't make sense to me.
>
> I have to say that I self-assigned the issue hours before this patch (I don't
> know when you started working on it because you haven't explained anything
> either), and that means I'll look into that recently since I've
@@ -951,7 +951,8 @@ static const Expr
*SubstituteConstraintExpressionWithoutSatisfaction(
DeclInfo.getDecl(), DeclInfo.getLexicalDeclContext(), /*Final=*/false,
/*Innermost=*/std::nullopt,
/*RelativeToPrimary=*/true,
- /*Pattern=*/nullptr, /*ForConstrain
https://github.com/jcsxky closed
https://github.com/llvm/llvm-project/pull/102554
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
> Note that @jcsxky has a similar patch #102554 that fixes the same thing. I
> don't intend to contend against him, and admittedly, that patch works.
>
> But I don't think that approach is so reasonable because it is hacky in that
> `ForConstraintInstantiation` is disabled in the
@@ -599,3 +599,39 @@ template
unsigned long DerivedCollection::index() {}
} // namespace GH72557
+
+namespace GH102320 {
+
+template
+concept Constrained = true;
+
+template class C {
+ template > class D;
+ template
+requires Constrained
+ class E;
+};
+
+template
jcsxky wrote:
> substitute so all references to template parameters have the correct depth
@sdkrystian Agree! The underlying issue is the incorrect depth makes the
comparison of the operands of the `noexcept-specifier` failed. because clang
can't find instantiated template parameter declaratio
https://github.com/jcsxky edited
https://github.com/llvm/llvm-project/pull/102267
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
@sdkrystian Could you please take another look at this patch? The approach
does what you said before.
When checking exception specific equivalence of the two functions, we do
instantiation and substitute all the template parameters with instantiated
ones. But we can't find them
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/87144
>From c4adc0ae83294e4524f2740a40eee483c2cb Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sat, 30 Mar 2024 14:47:00 +0800
Subject: [PATCH] [Clang][Sema] Skip checking anonymous enum in using enum
declaration
-
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/87314
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/87144
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1537,6 +1537,10 @@ void Sema::PushOnScopeChains(NamedDecl *D, Scope *S,
bool AddToContext) {
cast(D)->isFunctionTemplateSpecialization())
return;
+ if (isa(D) && D->getDeclName().isEmpty()) {
jcsxky wrote:
`Sema::ActOnUsingEnumDeclaration` inv
@@ -1537,6 +1537,10 @@ void Sema::PushOnScopeChains(NamedDecl *D, Scope *S,
bool AddToContext) {
cast(D)->isFunctionTemplateSpecialization())
return;
+ if (isa(D) && D->getDeclName().isEmpty()) {
jcsxky wrote:
These checks include name conflict an
@@ -1537,6 +1537,10 @@ void Sema::PushOnScopeChains(NamedDecl *D, Scope *S,
bool AddToContext) {
cast(D)->isFunctionTemplateSpecialization())
return;
+ if (isa(D) && D->getDeclName().isEmpty()) {
jcsxky wrote:
Ah, I see. I skip those checking when
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/87173
>From 51f3dc24417eb0b74f029b85b47519b6d152 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 31 Mar 2024 09:38:05 +0800
Subject: [PATCH] [Clang][Sema] set declaration invalid earlier to prevent
crash in calcu
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/87173
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
Still crash on
```cpp
template constexpr auto x = F();
template constexpr int a() { return 1; }
template
struct A {
using Func = decltype(
[](T) {
return x<[] constexpr { return a(); }>;
// return x<[] constexpr { return b(); }>;
}.template operator()('
jcsxky wrote:
> > Still crash on
> > ```c++
> > template constexpr auto x = F();
> > template constexpr int a() { return 1; }
> >
> > template
> > struct A {
> > using Func = decltype(
> > [](T) {
> > return x<[] constexpr { return a(); }>;
> > // return x<[] constexpr {
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/87173
>From 26da477eb3633880734c096b13f89cc0d557745b Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 31 Mar 2024 09:38:05 +0800
Subject: [PATCH] [Clang][Sema] set declaration invalid earlier to prevent
crash in calcu
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/87173
>From a0c0feae5bee318bcc253e5497994bfe78f308ee Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 31 Mar 2024 09:38:05 +0800
Subject: [PATCH] [Clang][Sema] set declaration invalid earlier to prevent
crash in calcu
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/85198
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/85198
>From a7bc05667f7280958e68fd82e01b620e18e4203c Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Thu, 14 Mar 2024 16:32:36 +0800
Subject: [PATCH] [Clang][Sema] Fix issue on requires expression with templated
base clas
https://github.com/jcsxky ready_for_review
https://github.com/llvm/llvm-project/pull/85198
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/85198
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -7735,7 +7735,8 @@ ExprResult Sema::BuildResolvedCallExpr(Expr *Fn,
NamedDecl *NDecl,
}
if (CXXMethodDecl *Method = dyn_cast_or_null(FDecl))
-if (Method->isImplicitObjectMemberFunction())
+if (!isa(CurContext) &&
jcsxky wrote:
In require body,
@@ -7735,7 +7735,8 @@ ExprResult Sema::BuildResolvedCallExpr(Expr *Fn,
NamedDecl *NDecl,
}
if (CXXMethodDecl *Method = dyn_cast_or_null(FDecl))
-if (Method->isImplicitObjectMemberFunction())
+if (!isa(CurContext) &&
jcsxky wrote:
Yeah, I think it
@@ -7735,7 +7735,8 @@ ExprResult Sema::BuildResolvedCallExpr(Expr *Fn,
NamedDecl *NDecl,
}
if (CXXMethodDecl *Method = dyn_cast_or_null(FDecl))
-if (Method->isImplicitObjectMemberFunction())
+if (!isa(CurContext) &&
jcsxky wrote:
@erichkeane I am
@@ -7735,7 +7735,8 @@ ExprResult Sema::BuildResolvedCallExpr(Expr *Fn,
NamedDecl *NDecl,
}
if (CXXMethodDecl *Method = dyn_cast_or_null(FDecl))
-if (Method->isImplicitObjectMemberFunction())
+if (!isa(CurContext) &&
jcsxky wrote:
Do you mean that
@@ -7735,7 +7735,8 @@ ExprResult Sema::BuildResolvedCallExpr(Expr *Fn,
NamedDecl *NDecl,
}
if (CXXMethodDecl *Method = dyn_cast_or_null(FDecl))
-if (Method->isImplicitObjectMemberFunction())
+if (!isa(CurContext) &&
jcsxky wrote:
And if only chec
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/85198
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/85198
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/85198
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky created
https://github.com/llvm/llvm-project/pull/94725
None
>From 9fc6172cb3ef627eb7d4e939dff6f4504c06150a Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 7 Jun 2024 14:04:52 +0800
Subject: [PATCH] [Clang][Sema] qualifier should be transformed
---
clang/lib/Sema/
https://github.com/jcsxky converted_to_draft
https://github.com/llvm/llvm-project/pull/94725
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/94725
>From 917cd980ed6a130b9f175492638afa22a1246c5c Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 7 Jun 2024 14:04:52 +0800
Subject: [PATCH] [Clang][Sema] qualifier should be transformed
---
clang/lib/Sema/SemaTe
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/94725
>From 6a90ef0b3947a0de2d6453856c80d8f0fd393548 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 7 Jun 2024 14:04:52 +0800
Subject: [PATCH] [Clang][Sema] qualifier should be transformed
---
clang/lib/Sema/TreeTr
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/94725
>From 57576620fc412015bd19a34e12be61f4b81eb655 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 7 Jun 2024 14:04:52 +0800
Subject: [PATCH] [Clang][Sema] qualifier should be transformed
---
clang/lib/Sema/TreeTr
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/94725
>From 2977f65d503c2a96247705ce50157870aaefa003 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 7 Jun 2024 14:04:52 +0800
Subject: [PATCH] [Clang][Sema] qualifier should be transformed
---
clang/docs/ReleaseNot
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/94725
>From a1754c56a3293cd6529244f9a0f7486f4912e18d Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 7 Jun 2024 14:04:52 +0800
Subject: [PATCH] [Clang][Sema] qualifier should be transformed
---
clang/docs/ReleaseNot
https://github.com/jcsxky edited https://github.com/llvm/llvm-project/pull/94725
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
crash on trunk assertion.
https://github.com/llvm/llvm-project/pull/94725
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky ready_for_review
https://github.com/llvm/llvm-project/pull/94725
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky created
https://github.com/llvm/llvm-project/pull/94942
Consider the testcase, return type of `construct_at` is
```cpp
DecltypeType 0x5570d8c0 'decltype(new struct BasicPersistent(declval()))' sugar dependent
|-CXXNewExpr 0x5570d880 'struct BasicPersistent *' Fu
jcsxky wrote:
> because we want to make the name of the function and any template parameter
refers to the instantiated function rather than that of the function template.
Does that mean we should transform the `SourceLocExpr` into a certain function
name when instantiating if it is `__builtin_
https://github.com/jcsxky created
https://github.com/llvm/llvm-project/pull/95190
improve `ASTStructuralEquivalenceTest`:
1. compare the depth and index of NTTP
2. provide comparison of `CXXDependentScopeMemberExpr` to `StmtCompare`.
>From 644c6e8499285e5b3ab17193ec63eed051dae583 Mon Sep 17 00
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/95190
>From 157f664408062da41f4d82d20ddc06e0e563fe31 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Wed, 12 Jun 2024 09:47:16 +0800
Subject: [PATCH] [StructuralEquivalence] improve NTTP and
CXXDependentScopeMemberExpr co
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/95190
>From ba081d51a0cc803188760eec2847bfc73d2192b8 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Wed, 12 Jun 2024 09:47:16 +0800
Subject: [PATCH] [StructuralEquivalence] improve NTTP and
CXXDependentScopeMemberExpr co
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/95190
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
> SourceLocation needs to be dependent because we want to make the name of the
> function and any template parameter refers to the instantiated function
> rather than that of the function template. This was changed in #78436
>
> The issue is that SourceLocation then is a dependen
jcsxky wrote:
> Needs changes as discussed.
> Needs changes as discussed.
I am really appreciate for your guidance and I will check in the weekend.
https://github.com/llvm/llvm-project/pull/94725
___
cfe-commits mailing list
cfe-commits@lists.llvm.
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/94942
>From 96f4e2a5c82296b61e53189135d88a2d2b0da9f4 Mon Sep 17 00:00:00 2001
From: Qizhi Hu <836744...@qq.com>
Date: Mon, 10 Jun 2024 16:53:54 +0800
Subject: [PATCH] [clang] SourceLocIdentKind::Function should not be de
jcsxky wrote:
```cpp
struct BasicPersistent;
struct SourceLocation {
static constexpr const char* Current(const char * func =
__builtin_FUNCTION()) {
return func;
}
};
template BasicPersistent &&__declval(int);
template auto declval() -> decltype(__declval<_Tp>(0));
jcsxky wrote:
> So, looked into this more. You are correct that `Function` needs not be
> dependent because we only ever show the name of the function unqualified.
> However, `FunctionSig` does. Here is an example of what we are trying to
> preserve https://godbolt.org/z/M3eTa8nn5 (the clang 1
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/94942
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
> This change has caused a regression in one of our systems integration tests
> that test static analysis for the bstring lib project
> (https://github.com/websnarf/bstrlib) with cross translation unit analysis
> enabled. Unfortunately I do not have a simple reproducer that stand
jcsxky wrote:
```cpp
ls
bstrwrap.cpp bstrwrap.h ctudir test.cpp test.plist test.sh
cat bstrwrap.cpp
#include "bstrwrap.h"
#include
Bstrlib::CBString::CBString () {
}
cat bstrwrap.h
#include
namespace Bstrlib {
struct CBString {
CBString ();
};
extern std::istream& getline (void);
}
cat
jcsxky wrote:
> Hi @jcsxky , I fetched and rebased to origin/main just now (6/16/2024 at
> 4:30pm Central US time), and rebuilt - and I see the crash. Did you try
> rebasing to latest source and rebuilding?
>
> `$ clang --analyze -Xclang -analyzer-config -Xclang
> experimental-enable-naive-ct
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/93411
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
@mizvekov After I apply you changes in this patch,
https://github.com/llvm/llvm-project/issues/91677 is still crash(although it
makes sense with `-ast-dump` option). I put it below for explanation clearly:
```cpp
template struct t1 {
template
struct t2 {};
};
template
t1::
jcsxky wrote:
> So After we have formed a TemplateSpecializationType, we are done with the
> NNS. We keep it around in an ElaboratedType for type sugar only, it should
> not be needed to compile the program correctly anymore.
>
> So I think this solution violates one important aspect of our AS
https://github.com/jcsxky created
https://github.com/llvm/llvm-project/pull/93923
Don't skip searching in `ToContext` during importing `EnumDecl`. And
`IsStructuralMatch` in `StructralEquivalence` can make sure to determine
whether the found result is match or not.
>From 7e602ae8d3c7ca0c3218d
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/93923
>From 7e602ae8d3c7ca0c3218d8ce9106510c43b6295b Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 31 May 2024 13:12:41 +0800
Subject: [PATCH 1/2] [clang][ASTImport] fix issue on anonymous enum import
---
clang/li
jcsxky wrote:
> Does this work on the following code?
>
> ```
> struct A {
> enum { E1,E2 } x;
> enum { E3,E4 } y;
> };
> ```
I have updated testcase according to your suggestion to demonstrate this
solution works correctly on the testcase above.
https://github.com/
@@ -9674,6 +9674,27 @@ TEST_P(ASTImporterOptionSpecificTestBase,
ImportInstantiatedFromMember) {
EXPECT_TRUE(ImportedPartialSpecialization->getInstantiatedFromMember());
}
+TEST_P(ASTImporterOptionSpecificTestBase, ImportAnonymousEnum) {
+ const char *ToCode =
+ R"(
+
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/93923
>From 7e602ae8d3c7ca0c3218d8ce9106510c43b6295b Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Fri, 31 May 2024 13:12:41 +0800
Subject: [PATCH 1/2] [clang][ASTImport] fix issue on anonymous enum import
---
clang/li
@@ -9674,6 +9674,40 @@ TEST_P(ASTImporterOptionSpecificTestBase,
ImportInstantiatedFromMember) {
EXPECT_TRUE(ImportedPartialSpecialization->getInstantiatedFromMember());
}
+AST_MATCHER_P(EnumDecl, hasEnumConstName, StringRef, ConstName) {
+ for (EnumConstantDecl *D : Node.
@@ -9674,6 +9674,40 @@ TEST_P(ASTImporterOptionSpecificTestBase,
ImportInstantiatedFromMember) {
EXPECT_TRUE(ImportedPartialSpecialization->getInstantiatedFromMember());
}
+AST_MATCHER_P(EnumDecl, hasEnumConstName, StringRef, ConstName) {
+ for (EnumConstantDecl *D : Node.
@@ -1442,19 +1442,27 @@ SourceLocation
CXXUnresolvedConstructExpr::getBeginLoc() const {
CXXDependentScopeMemberExpr::CXXDependentScopeMemberExpr(
const ASTContext &Ctx, Expr *Base, QualType BaseType, bool IsArrow,
SourceLocation OperatorLoc, NestedNameSpecifierLoc Qua
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/93923
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
> Ah, I had missed (thanks github review tool!) that the 'ImplicitObjectMember'
> part already existed. Sorry for that.
Never mind! Partly because I didn't make it more clear due to my poor
expression .
https://github.com/llvm/llvm-project/pull/85198
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/85198
>From 0076d87897371f3467c49818a7789cedda27e485 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Thu, 14 Mar 2024 16:32:36 +0800
Subject: [PATCH] [Clang][Sema] Fix issue on requires expression with templated
base clas
https://github.com/jcsxky closed https://github.com/llvm/llvm-project/pull/85198
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
jcsxky wrote:
gently ping. @erichkeane @shafik Any opinions on this pr?
https://github.com/llvm/llvm-project/pull/87173
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jcsxky updated
https://github.com/llvm/llvm-project/pull/87173
>From 19b2cab0c84a934910f65536a0627045d30b9729 Mon Sep 17 00:00:00 2001
From: huqizhi
Date: Sun, 31 Mar 2024 09:38:05 +0800
Subject: [PATCH] [Clang][Sema] set declaration invalid earlier to prevent
crash in calcu
301 - 400 of 474 matches
Mail list logo