@@ -745,9 +745,14 @@ bool Parser::ParseOpenACCClause(OpenACCDirectiveKind
DirKind) {
<< getCurToken().getIdentifierInfo();
// Consume the clause name.
- ConsumeToken();
+ SourceLocation ClauseLoc = ConsumeToken();
+
+ bool ParamsResult = ParseOpenACCClausePara
@@ -13662,3 +13663,8 @@ StringRef ASTContext::getCUIDHash() const {
CUIDHash = llvm::utohexstr(llvm::MD5Hash(LangOpts.CUID), /*LowerCase=*/true);
return CUIDHash;
}
+
+void ASTContext::setOpenACCStructuredBlock(OpenACCComputeConstruct *C,
+
@@ -0,0 +1,132 @@
+//===--- SemaOpenACC.cpp - Semantic Analysis for OpenACC constructs
---===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
@@ -0,0 +1,132 @@
+//===--- SemaOpenACC.cpp - Semantic Analysis for OpenACC constructs
---===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
https://github.com/erichkeane created
https://github.com/llvm/llvm-project/pull/81874
This patch is split off from #81659, and contains just the Sema infrastructure
that we can later use to implement semantic analysis of OpenACC constructs.
>From 35700522a658571e2abad279f327f4160fdb6c9d Mon Se
https://github.com/erichkeane commented:
@alexey-bataev : as requested, I've split off the infrastructure bits. Once
this is committed, I'll move the 'warning's as a Review-after-commit so that
the other patch can be easier to review.
https://github.com/llvm/llvm-project/pull/81874
__
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/81874
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1197,7 +1215,20 @@ StmtResult Parser::ParseOpenACCDirectiveStmt() {
ParsingOpenACCDirectiveRAII DirScope(*this);
ConsumeAnnotationToken();
- ParseOpenACCDirective();
+ OpenACCDirectiveParseInfo DirInfo = ParseOpenACCDirective();
+ if (getActions().ActOnStartOpenACCD
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/81874
>From 35700522a658571e2abad279f327f4160fdb6c9d Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Thu, 15 Feb 2024 08:41:58 -0800
Subject: [PATCH 1/2] [OpenACC][NFC] Implement basic OpenACC Sema
infrastructure
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/81874
>From 35700522a658571e2abad279f327f4160fdb6c9d Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Thu, 15 Feb 2024 08:41:58 -0800
Subject: [PATCH 1/3] [OpenACC][NFC] Implement basic OpenACC Sema
infrastructure
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/81874
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/81893
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
I wonder if this should be a part of the Targets in CodeGen instead of here?
https://github.com/llvm/llvm-project/pull/81893
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin
@@ -14,6 +14,7 @@
#ifndef LLVM_CLANG_BASIC_TARGETINFO_H
#define LLVM_CLANG_BASIC_TARGETINFO_H
+#include "clang/AST/Attr.h"
erichkeane wrote:
Basic shouldn't be referencing AST (IIRC, it shouldn't reference anything but
basic or llvm), this ends up being an u
erichkeane wrote:
> I wonder if this should be a part of the Targets in CodeGen instead of here?
Hrm, this is a bad idea as the rest of mangling is in AST, but having mangling
outside of AST seems to be the problem here.
https://github.com/llvm/llvm-project/pull/81893
___
@@ -0,0 +1,132 @@
+//===--- SemaOpenACC.cpp - Semantic Analysis for OpenACC constructs
---===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/81659
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2742,6 +2742,19 @@ bool Parser::parseMisplacedModuleImport() {
return false;
}
+void Parser::diagnoseUseOfC11Keyword(const Token& Tok) {
+ // Warn that this is a C11 extension if in an older mode or if in C++.
+ // Otherwise, warn that it is incompatible with standards
@@ -2742,6 +2742,19 @@ bool Parser::parseMisplacedModuleImport() {
return false;
}
+void Parser::diagnoseUseOfC11Keyword(const Token& Tok) {
+ // Warn that this is a C11 extension if in an older mode or if in C++.
+ // Otherwise, warn that it is incompatible with standards
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/82015
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/82037
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
erichkeane wrote:
> what would be the reason for windows build failing , is it a CI issue or
> specific to this PR & what can I do to resolve that. Thank you
That appears to be a problem with the CI itself. I think we've fixed up a
bunch of the CI, but it will require doing a 'merge' with mai
erichkeane wrote:
> This is going to be rather disruptive on downstream projects. At least we
> should wait until after the release of clang 18 to merge it, to avoid endless
> merge conflicts
For the most part, git will handle these pretty well on downstreams I think,
and as they are declarat
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/79035
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
Reviewed the CFE component, didn't look at LLVM.
https://github.com/llvm/llvm-project/pull/79035
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit
@@ -2705,6 +2705,33 @@ An error will be given if:
}];
}
+def AMDGPUMaxNumWorkGroupsDocs : Documentation {
+ let Category = DocCatAMDGPUAttributes;
+ let Content = [{
+This attribute specifies the max number of work groups when the kernel
+is dispatched.
+
+Clang supports t
@@ -2705,6 +2705,33 @@ An error will be given if:
}];
}
+def AMDGPUMaxNumWorkGroupsDocs : Documentation {
+ let Category = DocCatAMDGPUAttributes;
+ let Content = [{
+This attribute specifies the max number of work groups when the kernel
+is dispatched.
+
+Clang supports t
@@ -2705,6 +2705,33 @@ An error will be given if:
}];
}
+def AMDGPUMaxNumWorkGroupsDocs : Documentation {
+ let Category = DocCatAMDGPUAttributes;
+ let Content = [{
+This attribute specifies the max number of work groups when the kernel
+is dispatched.
+
+Clang supports t
@@ -8069,6 +8069,26 @@ static void handleAMDGPUNumVGPRAttr(Sema &S, Decl *D,
const ParsedAttr &AL) {
D->addAttr(::new (S.Context) AMDGPUNumVGPRAttr(S.Context, AL, NumVGPR));
}
+static void handleAMDGPUMaxNumWorkGroupsAttr(Sema &S, Decl *D,
+
erichkeane wrote:
I think we're good, feel free to resolve your conflict and commit.
https://github.com/llvm/llvm-project/pull/80842
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/82277
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
erichkeane wrote:
> @erichkeane
>
> > That said, waiting until after 18 is perhaps a good diea.
>
> Resolving merge conflicts that will arise in the meantime is not going to be
> trivial, but should be doable in a reasonable time. So I'm willing to wait.
>
I'm glad to hear that! I'm hopeful
@@ -8069,6 +8069,26 @@ static void handleAMDGPUNumVGPRAttr(Sema &S, Decl *D,
const ParsedAttr &AL) {
D->addAttr(::new (S.Context) AMDGPUNumVGPRAttr(S.Context, AL, NumVGPR));
}
+static void handleAMDGPUMaxNumWorkGroupsAttr(Sema &S, Decl *D,
+
erichkeane wrote:
Also note, this is missing Clang lit tests, and doesn't seem to be correctly
handling dependent expressions for x,y, and z.
https://github.com/llvm/llvm-project/pull/79035
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https
@@ -9442,9 +9442,21 @@ bool
SpecialMemberDeletionInfo::shouldDeleteForSubobjectCall(
int DiagKind = -1;
- if (SMOR.getKind() == Sema::SpecialMemberOverloadResult::NoMemberOrDeleted)
-DiagKind = !Decl ? 0 : 1;
- else if (SMOR.getKind() == Sema::SpecialMemberOverloadRe
@@ -188,3 +188,14 @@ static_assert(U2().b.x == 100, "");
static_assert(U3().b.x == 100, "");
} // namespace GH48416
+
+namespace GH81774 {
+struct Handle {
+Handle(int) {}
+};
+// Should be well-formed b/c NoState has a brace-or-equal-initializer
erichkean
erichkeane wrote:
> did I miss something - it looks like this was committed without approval?
It looks that way to me @haoNoQ : Did you commit this instead of something
else? Can you revert this until we get approval?
https://github.com/llvm/llvm-project/pull/80371
___
erichkeane wrote:
> Hmm, no, I landed it because I made an assumption that there's simply not
> that much interest in this work (I'm quite depressed about this in general
> lately) so as a code owner I just made a call that it's probably good enough
> to go and rely on post-commit review. Now
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/82417
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
1 nit, else LGTM. We should probably have a release note as well.
https://github.com/llvm/llvm-project/pull/82417
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/l
@@ -9706,9 +9706,17 @@ bool Sema::CheckFunctionTemplateSpecialization(
if (Result == Candidates.end())
return true;
- // Ignore access information; it doesn't figure into redeclaration checking.
FunctionDecl *Specialization = cast(*Result);
+ auto *SpecializationFP
erichkeane wrote:
> Ok gotcha thanks! In any case, I'll do my best to handle this more gracefully
> in the future. Your advice is always appreciated!
Perfect! I'll try to be better about this in the future as well.
https://github.com/llvm/llvm-project/pull/80371
__
https://github.com/erichkeane created
https://github.com/llvm/llvm-project/pull/82543
OpenACC3.3 2.5.4 says: "A program may not branch into or out of a compute
construct". While some of this restriction isn't particularly checkable,
'break' and 'continue' are possible and pretty trivial, so t
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/82543
>From 5ea47a31eb0ce851441cb7f1851b13303732ca91 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Wed, 21 Feb 2024 10:08:06 -0800
Subject: [PATCH 1/2] [OpenACC] Implement 'break' and 'continue' errors for
Comput
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
erichkeane wrote:
> > Also note, this is missing Clang lit tests, and doesn't seem to be
> > correctly handling dependent expressions for x,y, and z.
>
> What does it mean to "handle dependent expressions for x,y, and z"? Thanks!
An expression can be 'dependent', which is a C++'ism for 'has so
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/82543
>From 5ea47a31eb0ce851441cb7f1851b13303732ca91 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Wed, 21 Feb 2024 10:08:06 -0800
Subject: [PATCH 1/3] [OpenACC] Implement 'break' and 'continue' errors for
Comput
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
@@ -3371,6 +3379,20 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope
*CurScope) {
if (S->isOpenMPLoopScope())
return StmtError(Diag(BreakLoc, diag::err_omp_loop_cannot_use_stmt)
<< "break");
+
+ // OpenACC doesn't allow 'break'ing from a compu
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/81418
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
Not the best one to review this, but some drive-bys
https://github.com/llvm/llvm-project/pull/81418
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com
@@ -263,6 +263,14 @@ namespace {
}
}
+QualType Expr::getEnumCoercedType(const ASTContext &Ctx) const {
+ bool NotEnumType = dyn_cast(this->getType()) == nullptr;
+ if (NotEnumType)
erichkeane wrote:
```suggestion
if (!isa(this->getType()))
```
Though,
@@ -4097,6 +4105,14 @@ FieldDecl *Expr::getSourceBitField() {
return nullptr;
}
+EnumConstantDecl *Expr::getEnumConstantDecl() {
+ Expr *E = this->IgnoreParenImpCasts();
+ if (DeclRefExpr *DRE = dyn_cast(E))
+if (EnumConstantDecl *ECD = dyn_cast(DRE->getDecl()))
--
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/82543
>From 5ea47a31eb0ce851441cb7f1851b13303732ca91 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Wed, 21 Feb 2024 10:08:06 -0800
Subject: [PATCH 1/4] [OpenACC] Implement 'break' and 'continue' errors for
Comput
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/82543
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -6490,6 +6490,15 @@ static void HandleBTFTypeTagAttribute(QualType &Type,
const ParsedAttr &Attr,
TypeProcessingState &State) {
Sema &S = State.getSema();
+ // This attribute is only supported in C.
+ // FIXME: we should implement
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/107238
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -225,6 +225,11 @@ Attribute Changes in Clang
more cases where the returned reference outlives the object.
(#GH100567)
+- Now correctly diagnosing use of ``btf_type_tag`` in C++ and ignoring it; this
erichkeane wrote:
```suggestion
- Clang now correctly
@@ -225,6 +225,11 @@ Attribute Changes in Clang
more cases where the returned reference outlives the object.
(#GH100567)
+- Now correctly diagnosing use of ``btf_type_tag`` in C++ and ignoring it; this
+ attribute is a C-only attribute, and was causing crashes with templa
@@ -0,0 +1,1566 @@
+//=== SemaFunctionEffects.cpp - Sema handling of function effects
-===//
erichkeane wrote:
I've had a hard time with the review of this file, so I haven't done a close
look. Hopefully someone who understands this better than me has
@@ -8392,6 +8397,20 @@ void ASTReader::InitializeSema(Sema &S) {
NewOverrides.applyOverrides(SemaObj->getLangOpts());
}
+ if (!DeclsWithEffectsToVerify.empty()) {
+for (GlobalDeclID ID : DeclsWithEffectsToVerify) {
+ Decl *D = GetDecl(ID);
+ FunctionEf
@@ -0,0 +1,1566 @@
+//=== SemaFunctionEffects.cpp - Sema handling of function effects
-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: A
@@ -4932,6 +4938,78 @@ class FunctionEffectsRef {
void dump(llvm::raw_ostream &OS) const;
};
+/// A mutable set of FunctionEffect::Kind.
+class FunctionEffectKindSet {
+ // For now this only needs to be a bitmap.
+ constexpr static size_t EndBitPos = 8;
+ using KindBitsT
@@ -13559,6 +13562,27 @@ QualType Sema::CheckAssignmentOperands(Expr *LHSExpr,
ExprResult &RHS,
QualType LHSType = LHSExpr->getType();
QualType RHSType = CompoundType.isNull() ? RHS.get()->getType() :
CompoundType;
+
+ if (RHS.
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/106321
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
I did a pass, I think @Sirraide is on the right direction in his reviews here,
but the general direction of this patch is also completely acceptable.
https://github.com/llvm/llvm-project/pull/106321
___
cfe-com
@@ -186,4 +218,370 @@ bool Sema::CheckCountedByAttrOnField(FieldDecl *FD, Expr
*E, bool CountInBytes,
return false;
}
+SourceRange Sema::BoundsSafetySourceRangeFor(const CountAttributedType *CATy) {
+ // Note: This implementation relies on `CountAttributedType` being uniqu
@@ -3343,6 +3363,8 @@ class CountAttributedType final
static bool classof(const Type *T) {
return T->getTypeClass() == CountAttributed;
}
+
+ StringRef GetAttributeName(bool WithMacroPrefix) const;
erichkeane wrote:
```suggestion
StringRef getAttrib
@@ -186,4 +218,370 @@ bool Sema::CheckCountedByAttrOnField(FieldDecl *FD, Expr
*E, bool CountInBytes,
return false;
}
+SourceRange Sema::BoundsSafetySourceRangeFor(const CountAttributedType *CATy) {
erichkeane wrote:
I agree with Sirraide here, but would h
erichkeane wrote:
Rather than this being "not added in the header file", should we just make this
one of the attributes that is disallowed after the thing has been 'referenced'?
Or is that a dumb suggestion here?
https://github.com/llvm/llvm-project/pull/67520
https://github.com/erichkeane commented:
I've not done as in depth of a review as Corentin, but I approve of the
direction here, I think the approach is correct, and most of the changes are
fairly mechanical. So once Corentin is happy with the changes, so am I.
https://github.com/llvm/llvm-pr
@@ -10950,6 +10950,51 @@ def warn_imp_cast_drops_unaligned : Warning<
InGroup>;
// Function effects
+def warn_func_effect_violation : Warning<
+ "'%0' %select{function|constructor|destructor|lambda|block|constructor's
member initializer}1 "
erichkeane wrot
@@ -15099,6 +15037,106 @@ class Sema final : public SemaBase {
std::string getFixItZeroLiteralForType(QualType T, SourceLocation Loc) const;
///@}
+
+ //
erichkeane wrote:
@endilll ?
https://github.com/llvm/llvm-project/pull/99656
__
@@ -4932,6 +4938,78 @@ class FunctionEffectsRef {
void dump(llvm::raw_ostream &OS) const;
};
+/// A mutable set of FunctionEffect::Kind.
+class FunctionEffectKindSet {
+ // For now this only needs to be a bitmap.
+ constexpr static size_t EndBitPos = 8;
+ using KindBitsT
@@ -10950,6 +10950,51 @@ def warn_imp_cast_drops_unaligned : Warning<
InGroup>;
// Function effects
+def warn_func_effect_violation : Warning<
+ "'%0' %select{function|constructor|destructor|lambda|block|constructor's
member initializer}1 "
erichkeane wrot
@@ -8392,6 +8397,20 @@ void ASTReader::InitializeSema(Sema &S) {
NewOverrides.applyOverrides(SemaObj->getLangOpts());
}
+ if (!DeclsWithEffectsToVerify.empty()) {
+for (GlobalDeclID ID : DeclsWithEffectsToVerify) {
+ Decl *D = GetDecl(ID);
+ FunctionEf
@@ -0,0 +1,1566 @@
+//=== SemaFunctionEffects.cpp - Sema handling of function effects
-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: A
@@ -0,0 +1,1566 @@
+//=== SemaFunctionEffects.cpp - Sema handling of function effects
-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: A
https://github.com/erichkeane commented:
I'm happy enough with it as is, I'd like @Sirraide to do 1 last pass, but if he
approves, so do I.
https://github.com/llvm/llvm-project/pull/99656
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https:/
@@ -2943,6 +2943,9 @@ class Parser : public CodeCompletionHandler {
return false;
}
+ bool ParseGNUSingleAttribute(ParsedAttributes &Attrs, SourceLocation &EndLoc,
erichkeane wrote:
I don't have a preference for any of the 3 names, but a comment explai
@@ -2287,6 +2288,15 @@ APValue SourceLocExpr::EvaluateInContext(const
ASTContext &Ctx,
Context = getParentContext();
}
+ // If we are currently parsing a lambda declarator, we might not have a fully
+ // formed call operator declaration yet, and we could not form a fu
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/107411
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/107411
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
erichkeane wrote:
Woops! Had the wrong tab open and typed in the wrong 'fixes', did not mean to
close this.
The patch was supposed to fix https://github.com/llvm/llvm-project/issues/107052
https://github.com/llvm/llvm-project/pull/107411
___
cfe-com
https://github.com/erichkeane reopened
https://github.com/llvm/llvm-project/pull/107411
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -9219,7 +9222,8 @@ class Sema final : public SemaBase {
/// \returns true if an error occurred, false otherwise.
bool CheckTemplateArgumentList(
TemplateDecl *Template, SourceLocation TemplateLoc,
- TemplateArgumentListInfo &TemplateArgs, bool PartialTemplateA
erichkeane wrote:
> That might not be enough. A function might not be used (or even referenced)
> in the TU that defines it, but only in other TUs. But it would certainly
> catch a number of issues already.
Right, though catching that ends up being pretty impossible. The most you could
do is
erichkeane wrote:
It appears that https://github.com/llvm/llvm-project/pull/95112 is actually
pretty close... are we better off holding off on this until after that goes in?
https://github.com/llvm/llvm-project/pull/107451
___
cfe-commits mailing l
@@ -2943,6 +2943,9 @@ class Parser : public CodeCompletionHandler {
return false;
}
+ bool ParseGNUSingleAttribute(ParsedAttributes &Attrs, SourceLocation &EndLoc,
erichkeane wrote:
Ah, I see. The WG14 specified one is `__builtin_has_c_attribute`, cor
https://github.com/erichkeane commented:
I'm not sold on this patch, particularly the changes to the overload.
I also wonder if we would better off having `CXXRecordDecl` save its 'variable'
for lambdas (and look it up from there) rather than this.
https://github.com/llvm/llvm-project/pull/1
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/101857
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2390,7 +2390,8 @@ static bool LookupQualifiedNameInUsingDirectives(Sema &S,
LookupResult &R,
}
bool Sema::LookupQualifiedName(LookupResult &R, DeclContext *LookupCtx,
- bool InUnqualifiedLookup) {
+ bool InUnqual
@@ -10204,15 +10205,14 @@ class Sema final : public SemaBase {
/// both @c a1 and @c a2. If @p SuppressUserConversions, then don't
/// allow user-defined conversions via constructors or conversion
/// operators.
- void
- AddMethodCandidate(CXXMethodDecl *Method, DeclAcc
@@ -4022,7 +4022,10 @@
CodeCompleteConsumer::OverloadCandidate::CreateSignatureString(
std::string Name;
llvm::raw_string_ostream OS(Name);
-FDecl->getDeclName().print(OS, Policy);
+auto const DeclName = (getKind() == CK_Lambda)
erichkeane wro
1701 - 1800 of 5434 matches
Mail list logo