@@ -2705,6 +2705,30 @@ An error will be given if:
}];
}
+def AMDGPUNumWorkGroupsDocs : Documentation {
+ let Category = DocCatAMDGPUAttributes;
+ let Content = [{
+The number of work groups specifies the number of work groups when the kernel
+is dispatched.
+
+Clang
@@ -2705,6 +2705,30 @@ An error will be given if:
}];
}
+def AMDGPUNumWorkGroupsDocs : Documentation {
+ let Category = DocCatAMDGPUAttributes;
+ let Content = [{
+The number of work groups specifies the number of work groups when the kernel
erichkeane
@@ -2705,6 +2705,30 @@ An error will be given if:
}];
}
+def AMDGPUNumWorkGroupsDocs : Documentation {
+ let Category = DocCatAMDGPUAttributes;
+ let Content = [{
+The number of work groups specifies the number of work groups when the kernel
+is dispatched.
+
+Clang
@@ -2031,6 +2031,13 @@ def AMDGPUNumVGPR : InheritableAttr {
let Subjects = SubjectList<[Function], ErrorDiag, "kernel functions">;
}
+def AMDGPUNumWorkGroups : InheritableAttr {
+ let Spellings = [Clang<"amdgpu_num_work_groups", 0>];
+ let Args =
@@ -57,7 +57,7 @@ UNION(char[2], short) u2 = { .one = { 'a', 'b' } }; //
ext-warning 3 {{'_Static_
typedef UNION(char, short) U3; // expected-error {{static assertion failed due
to requirement 'sizeof(char) == sizeof(short)': type size mismatch}} \
https://github.com/erichkeane commented:
This would need a release note + I think it needs better testing.
@AaronBallman might wish to take a look as well, this is his code ownership.
https://github.com/llvm/llvm-project/pull/81298
___
cfe-commits
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/81298
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
=?utf-8?q?“Nhat?= ,
=?utf-8?q?“Nhat?= ,
=?utf-8?q?“Nhat?= ,
=?utf-8?q?“Nhat?= ,
=?utf-8?q?“Nhat?= ,Nhat Nguyen
Message-ID:
In-Reply-To:
erichkeane wrote:
Looks like all the tests disappeared? Only thing I see is the code change.
Also, no release note is currently present.
@@ -11445,11 +11452,16 @@ static void DiagnoseBadDeduction(Sema , NamedDecl
*Found, Decl *Templated,
(ParamD = Param.dyn_cast()) ||
(ParamD = Param.dyn_cast()) ||
(ParamD = Param.dyn_cast());
- switch (DeductionFailure.Result) {
- case Sema::TDK_Success:
-
@@ -33,6 +33,7 @@ namespace clang {
class Decl;
struct DeducedPack;
class Sema;
+enum class TemplateDeductionResult;
erichkeane wrote:
should we specify the underlying type in all of these? I wonder if we can just
specify it as `uint8_t`? Would mean not
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/74512
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -6,28 +6,36 @@
// RUN: %clang_cc1 -std=c++23 %s -triple x86_64-linux-gnu -emit-llvm
-disable-llvm-passes -o - -fexceptions -fcxx-exceptions -pedantic-errors |
llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK
// RUN: %clang_cc1 -std=c++2c %s -triple x86_64-linux-gnu
https://github.com/erichkeane approved this pull request.
LGTM, make sure @cor3ntin is happy too though.
https://github.com/llvm/llvm-project/pull/80823
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/80823
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,33 @@
+// RUN: %clang_cc1 -std=c++98 %s -triple x86_64-linux-gnu -emit-llvm
-disable-llvm-passes -o - -fexceptions -fcxx-exceptions -pedantic-errors |
llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK
+// RUN: %clang_cc1 -std=c++11 %s -triple x86_64-linux-gnu
@@ -0,0 +1,51 @@
+// RUN: %clang_cc1 -std=c++98 %s -triple x86_64-linux-gnu -emit-llvm
-disable-llvm-passes -o - -fexceptions -fcxx-exceptions -pedantic-errors |
llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK
+// RUN: %clang_cc1 -std=c++11 %s -triple x86_64-linux-gnu
@@ -0,0 +1,142 @@
+//===- StmtOpenACC.h - Classes for OpenACC directives --*- C++
-*-===//
+//
+// 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:
@@ -0,0 +1,43 @@
+// RUN: %clang_cc1 -std=c++98 %s -triple x86_64-linux-gnu -emit-llvm
-disable-llvm-passes -O0 -o - -fexceptions -fcxx-exceptions -pedantic-errors |
llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK
+// RUN: %clang_cc1 -std=c++11 %s -triple x86_64-linux-gnu
@@ -0,0 +1,33 @@
+// RUN: %clang_cc1 -std=c++98 %s -triple x86_64-linux-gnu -emit-llvm
-disable-llvm-passes -o - -fexceptions -fcxx-exceptions -pedantic-errors |
llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK
+// RUN: %clang_cc1 -std=c++11 %s -triple x86_64-linux-gnu
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/81188
>From b7ca554663c4d0994ac255ee17ac016ef94f6778 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Thu, 8 Feb 2024 07:56:30 -0800
Subject: [PATCH 1/4] [OpenACC] Implement AST for OpenACC Compute Constructs
@@ -2145,7 +2145,11 @@ enum CXCursorKind {
*/
CXCursor_OMPScopeDirective = 306,
- CXCursor_LastStmt = CXCursor_OMPScopeDirective,
+ /** OpenACC Compute Construct.
+ */
+ CXCursor_OpenACCComputeConstruct = 307,
erichkeane wrote:
Thats a good idea,
@@ -0,0 +1,142 @@
+//===- StmtOpenACC.h - Classes for OpenACC directives --*- C++
-*-===//
+//
+// 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:
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/81188
>From b7ca554663c4d0994ac255ee17ac016ef94f6778 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Thu, 8 Feb 2024 07:56:30 -0800
Subject: [PATCH 1/3] [OpenACC] Implement AST for OpenACC Compute Constructs
erichkeane wrote:
> cc @erichkeane @AaronBallman
I looked through and don't see anything of concern to me that you haven't
covered. I am on the fence as to whether this warning makes sense to have in
this situation.
The point of the warning isn't that the language has a problem, it is
@@ -3780,6 +3780,30 @@ static void handleCleanupAttr(Sema , Decl *D, const
ParsedAttr ) {
<< NI.getName() << ParamTy << Ty;
return;
}
+ VarDecl *VD = cast(D);
+ // Create a reference to the variable declaration. This is a fake/dummy
+ // reference.
+
@@ -0,0 +1,140 @@
+//===- StmtOpenACC.h - Classes for OpenACC directives --*- C++
-*-===//
+//
+// 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:
@@ -0,0 +1,140 @@
+//===- StmtOpenACC.h - Classes for OpenACC directives --*- C++
-*-===//
+//
+// 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:
@@ -2838,6 +2838,27 @@ void
ASTStmtWriter::VisitOMPTargetParallelGenericLoopDirective(
Code = serialization::STMT_OMP_TARGET_PARALLEL_GENERIC_LOOP_DIRECTIVE;
}
+//===--===//
+// OpenACC
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/81188
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane created
https://github.com/llvm/llvm-project/pull/81188
'serial', 'parallel', and 'kernel' constructs are all considered
'Compute' constructs. This patch creates the AST type, plus the required
infrastructure for such a type, plus some base types that will be
https://github.com/erichkeane approved this pull request.
This seems right to me, though a 2nd reviewer would be nice. I don't think we
should wait for CI on this due to it fixing a bot-breakage.
https://github.com/llvm/llvm-project/pull/81171
___
erichkeane wrote:
> Looks like there is a test
> (`clang-tools-extra/test/clang-tidy/infrastructure/diagnostic.cpp`) that
> contains the following:
>
> ```c++
> #ifdef PR64602 // Should not crash
> template
> struct S
> {
> auto foo(auto);
> };
>
> template <>
> auto S<>::foo(auto)
> {
erichkeane wrote:
> > > We also need to figure out what to do w/ `clang::assume`, because the
> > > entire situation with the two being separate attributes is a bit of a
> > > mess, as @erichkeane also pointed out. That can probably be resolved
> > > separately from the RFC, however—though
erichkeane wrote:
> Looks like there is a test
> (`clang-tools-extra/test/clang-tidy/infrastructure/diagnostic.cpp`) that
> contains the following:
>
> ```c++
> #ifdef PR64602 // Should not crash
> template
> struct S
> {
> auto foo(auto);
> };
>
> template <>
> auto S<>::foo(auto)
> {
erichkeane wrote:
> We also need to figure out what to do w/ `clang::assume`, because the entire
> situation with the two being separate attributes is a bit of a mess, as
> @erichkeane also pointed out. That can probably be resolved separately from
> the RFC, however—though I’m not that
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/80864
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
erichkeane wrote:
> Should I fix the conflict in the release notes myself, or should that be done
> when this gets merged? Because at least in my experience, merge conflicts in
> the release notes just keep reappearing if a pr stays open for some time...
Lets hang out on that for a bit...
erichkeane wrote:
> > I think the confusion/conflict between this and clang::assume needs to be
> > figured out. These two should just be, as close as possible, spellings of
> > the same thing.
>
> Well, apparently, `clang::assume` always takes a string and is meant for OMP
> assumptions, so
erichkeane wrote:
> > We have 2 options:
> >
> > * Wait for llvm to get improve their handling of assumption based
> > optimizations.
> > * Proceed with this work hoping this encourages work on the optimizer.
>
> The standard also mentions that `__has_cpp_attribute` should return `0` ‘if
>
erichkeane wrote:
Also note, we need to update the feature-test-macro/has_attribute-expr here.
https://github.com/llvm/llvm-project/pull/81014
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -1996,6 +1996,30 @@ Here is an example:
}];
}
+def AssumeDocs : Documentation {
+ let Category = DocCatStmt;
+ let Heading = "assume";
+ let Content = [{
+The ``assume`` attribute is used to indicate to the optimizer that a
+certain condition can be assumed to be true
@@ -1996,6 +1996,30 @@ Here is an example:
}];
}
+def AssumeDocs : Documentation {
+ let Category = DocCatStmt;
+ let Heading = "assume";
+ let Content = [{
+The ``assume`` attribute is used to indicate to the optimizer that a
+certain condition can be assumed to be true
@@ -1996,6 +1996,30 @@ Here is an example:
}];
}
+def AssumeDocs : Documentation {
+ let Category = DocCatStmt;
+ let Heading = "assume";
+ let Content = [{
+The ``assume`` attribute is used to indicate to the optimizer that a
+certain condition can be assumed to be true
@@ -4528,6 +4528,54 @@ static bool
IsBuiltInOrStandardCXX11Attribute(IdentifierInfo *AttrName,
}
}
+/// Parse the argument to C++23's [[assume()]] attribute.
+bool Parser::ParseAssumeAttributeArg(ParsedAttributes ,
+ IdentifierInfo
@@ -783,6 +783,9 @@ def err_ms_property_expected_comma_or_rparen : Error<
def err_ms_property_initializer : Error<
"property declaration cannot have a default member initializer">;
+def err_assume_attr_expects_cond_expr : Error<
+ "use of this expression in an 'assume'
@@ -4528,6 +4528,54 @@ static bool
IsBuiltInOrStandardCXX11Attribute(IdentifierInfo *AttrName,
}
}
+/// Parse the argument to C++23's [[assume()]] attribute.
+bool Parser::ParseAssumeAttributeArg(ParsedAttributes ,
erichkeane wrote:
Hopefully someone more
@@ -1996,6 +1996,30 @@ Here is an example:
}];
}
+def AssumeDocs : Documentation {
+ let Category = DocCatStmt;
+ let Heading = "assume";
+ let Content = [{
+The ``assume`` attribute is used to indicate to the optimizer that a
+certain condition can be assumed to be true
@@ -3780,6 +3780,30 @@ static void handleCleanupAttr(Sema , Decl *D, const
ParsedAttr ) {
<< NI.getName() << ParamTy << Ty;
return;
}
+ VarDecl *VD = cast(D);
+ // Create a reference to the variable declaration. This is a fake/dummy
+ // reference.
+
@@ -3780,6 +3780,30 @@ static void handleCleanupAttr(Sema , Decl *D, const
ParsedAttr ) {
<< NI.getName() << ParamTy << Ty;
return;
}
+ VarDecl *VD = cast(D);
+ // Create a reference to the variable declaration. This is a fake/dummy
+ // reference.
+
@@ -3780,6 +3780,30 @@ static void handleCleanupAttr(Sema , Decl *D, const
ParsedAttr ) {
<< NI.getName() << ParamTy << Ty;
return;
}
+ VarDecl *VD = cast(D);
+ // Create a reference to the variable declaration. This is a fake/dummy
+ // reference.
+
@@ -3780,6 +3780,30 @@ static void handleCleanupAttr(Sema , Decl *D, const
ParsedAttr ) {
<< NI.getName() << ParamTy << Ty;
return;
}
+ VarDecl *VD = cast(D);
+ // Create a reference to the variable declaration. This is a fake/dummy
+ // reference.
+
@@ -7894,13 +7895,18 @@ bool
Sema::CheckExplicitlyDefaultedSpecialMember(CXXMethodDecl *MD,
if (ShouldDeleteForTypeMismatch || ShouldDeleteSpecialMember(MD, CSM)) {
if (First) {
SetDeclDeleted(MD, MD->getLocation());
- if (!inTemplateInstantiation() &&
@@ -380,7 +375,8 @@ class DeclSpec {
unsigned FS_noreturn_specified : 1;
// friend-specifier
- unsigned Friend_specified : 1;
+ unsigned FriendSpecified : 1;
erichkeane wrote:
I think you're right, thats the one!
@@ -145,6 +145,7 @@ Improvements to Clang's diagnostics
prints.
- Clang now diagnoses member template declarations with multiple declarators.
+- Clang now diagnoses friend declarations with an ``enum``
elaborated-type-specifier outside of C++98.
erichkeane
@@ -2552,10 +2552,10 @@ class Parser : public CodeCompletionHandler {
/// Starting with a scope specifier, identifier, or
/// template-id that refers to the current class, determine whether
/// this is a constructor declarator.
- bool isConstructorDeclarator(
-
@@ -145,6 +145,7 @@ Improvements to Clang's diagnostics
prints.
- Clang now diagnoses member template declarations with multiple declarators.
+- Clang now diagnoses friend declarations with an ``enum``
elaborated-type-specifier outside of C++98.
erichkeane
@@ -380,7 +375,8 @@ class DeclSpec {
unsigned FS_noreturn_specified : 1;
// friend-specifier
- unsigned Friend_specified : 1;
+ unsigned FriendSpecified : 1;
erichkeane wrote:
Should these have that debug-attribute that we added not long ago? I think
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/80864
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -9759,7 +9759,7 @@ Sema::ActOnFunctionDeclarator(Scope *S, Declarator ,
DeclContext *DC,
SmallVector TemplateParamLists;
llvm::append_range(TemplateParamLists, TemplateParamListsRef);
if (TemplateParameterList *Invented = D.getInventedTemplateParameterList()) {
-
@@ -19294,7 +19294,16 @@ void Sema::ActOnStartFunctionDeclarationDeclarator(
ExplicitLists, /*IsFriend=*/false, IsMemberSpecialization, IsInvalid,
/*SuppressDiagnostic=*/true);
}
- if (ExplicitParams) {
+ // C++23 [dcl.fct]p23:
+ // An abbreviated
@@ -9759,7 +9759,7 @@ Sema::ActOnFunctionDeclarator(Scope *S, Declarator ,
DeclContext *DC,
SmallVector TemplateParamLists;
llvm::append_range(TemplateParamLists, TemplateParamListsRef);
if (TemplateParameterList *Invented = D.getInventedTemplateParameterList()) {
-
erichkeane wrote:
> Umm how could I resolve that? I tried various things but none working. 沈
You'll have to spend some time in a debugger (note that
`clang::DiagnosticIDs::EmitDiag` is where the diagnostic happens, so is a good
place for a brekapoint). But I see that in your creation of your
erichkeane wrote:
> ```
> extern void free(void *);
> extern void *malloc(size_t size);
> void t8(void) {
> void *p __attribute__((cleanup(free))) = malloc(10); //
> expected-warning{{attempt to call free on non-heap object 'p'}}
> }
> ```
>
> I added this, but I am getting this error:
@@ -6295,22 +6297,36 @@ bool Sema::diagnoseQualifiedDeclaration(CXXScopeSpec
, DeclContext *DC,
<< FixItHint::CreateRemoval(TemplateId->TemplateKWLoc);
NestedNameSpecifierLoc SpecLoc(SS.getScopeRep(), SS.location_data());
- while (SpecLoc.getPrefix()) {
+ do {
@@ -6295,22 +6297,36 @@ bool Sema::diagnoseQualifiedDeclaration(CXXScopeSpec
, DeclContext *DC,
<< FixItHint::CreateRemoval(TemplateId->TemplateKWLoc);
NestedNameSpecifierLoc SpecLoc(SS.getScopeRep(), SS.location_data());
- while (SpecLoc.getPrefix()) {
+ do {
https://github.com/erichkeane commented:
Added other reviewers, this part of naming is something that I need other eyes
on.
https://github.com/llvm/llvm-project/pull/80842
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://github.com/erichkeane edited
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
Timm =?utf-8?q?Bäder?= ,
Timm =?utf-8?q?Bäder?= ,
Timm =?utf-8?q?Bäder?= ,
Timm =?utf-8?q?Bäder?= ,
Timm =?utf-8?q?Bäder?=
Message-ID:
In-Reply-To:
@@ -8938,6 +8957,11 @@ static void processTypeAttrs(TypeProcessingState ,
QualType ,
attr.setUsedAsTypeAttr();
@@ -1613,8 +1613,8 @@ namespace {
bool TemplateInstantiator::AlreadyTransformed(QualType T) {
if (T.isNull())
return true;
-
- if (T->isInstantiationDependentType() || T->isVariablyModifiedType())
+ if (T->isInstantiationDependentType() || T->isVariablyModifiedType()
https://github.com/erichkeane approved this pull request.
This'll need a cherry pick to 18 as it is a break against 17, right? Otherwise
LGTM.
https://github.com/llvm/llvm-project/pull/80730
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -19706,22 +19706,29 @@ static void buildLambdaCaptureFixit(Sema ,
LambdaScopeInfo *LSI,
}
}
+static DeclContext *ignoreReuquiresBodyDecl(DeclContext *DC) {
erichkeane wrote:
```suggestion
static DeclContext *ignoreRequiresBodyDecl(DeclContext *DC) {
@@ -0,0 +1,25 @@
+// RUN: %clang -fsyntax-only -std=c++20 -Xclang -verify %s
+
+// expected-no-diagnostics
+
+auto GH69307_Func_1() {
+ constexpr auto b = 1;
+ return [&](auto c) -> int
erichkeane wrote:
Can you do a similar test with NO capture here? To show
@@ -19706,22 +19706,29 @@ static void buildLambdaCaptureFixit(Sema ,
LambdaScopeInfo *LSI,
}
}
+static DeclContext *ignoreReuquiresBodyDecl(DeclContext *DC) {
erichkeane wrote:
Name here doesn't match what you're doing here. Perhaps something closer to
@@ -0,0 +1,7 @@
+// RUN: %clang_cc1 -fsyntax-only -Wunused-lambda-capture
-Wused-but-marked-unused -Wno-uninitialized -verify -std=c++20 %s
+
+void test() {
+ int i;
+ auto explicit_by_value_unused_requires = [i] (auto) requires requires { i; }
{}; // expected-warning{{lambda
https://github.com/erichkeane approved this pull request.
Seems reasonable.
https://github.com/llvm/llvm-project/pull/80652
___
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/80594
___
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/80439
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,24 @@
+// RUN: not %clang_cc1 -std=c++2c -ast-dump %s | FileCheck %s
+
+namespace InvalidPacksShouldNotCrash {
+
+struct NotAPack;
+template typename Tp>
+void not_pack() {
+int i = 0;
+i...[0]; // expected-error {{i does not refer to the name of a parameter
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/78595
___
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/80359
___
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.
LGTM other than generalizing the test a bit.
https://github.com/llvm/llvm-project/pull/80439
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
@@ -0,0 +1,24 @@
+// RUN: not %clang_cc1 -std=c++2c -ast-dump %s | FileCheck %s
+
+namespace InvalidPacksShouldNotCrash {
+
+struct NotAPack;
+template typename Tp>
+void not_pack() {
+int i = 0;
+i...[0]; // expected-error {{i does not refer to the name of a parameter
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret(
// Prepare source highlighting information for the lines we're about to
// emit, starting from the first line.
std::unique_ptr[]> SourceStyles =
- highlightLines(BufStart, Lines.first, Lines.second, PP,
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/80442
___
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/80442
___
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.
I don't see much value in a backport, particularly since this affects back to
Clang 12. Else, LGTM.
https://github.com/llvm/llvm-project/pull/80395
___
cfe-commits mailing list
@@ -147,6 +147,20 @@ bool BugSuppression::isSuppressed(const
PathDiagnosticLocation ,
// done as well as perform a lot of work we'll never need.
// Gladly, none of our on-by-default checkers currently need it.
DeclWithIssue = ACtx.getTranslationUnitDecl();
+ }
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/80288
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
Other than release note, this LGTM.
https://github.com/llvm/llvm-project/pull/80359
___
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.
This looks right to me.
https://github.com/llvm/llvm-project/pull/80338
___
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'm not the best reviewer for this, but it looks reasonable to me. Perhaps
Aaron should take a look to make sure?
https://github.com/llvm/llvm-project/pull/80327
___
cfe-commits mailing list
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/79760
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
erichkeane wrote:
> @erichkeane How does this sound?
>
> > Removed support for constructing on-stack `TemplateArgumentList`s;
> > interfaces should instead use `ArrayRef` to pass template
> > arguments. Transitioning internal uses to `ArrayRef`
> > reduces AST memory usage by 0.4% when
https://github.com/erichkeane approved this pull request.
I think this looks fine now... WDYT @cor3ntin ?
https://github.com/llvm/llvm-project/pull/78243
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
erichkeane wrote:
> @erichkeane I ended up writing a python script that compiles the TUs in
> `clang/lib` with `-print-stats` and then sums up the total bytes allocated by
> `ASTContext`. Ended up with a 0.4% decrease in memory usage.
>
> This does however rely on `compile_commands.json`, and
@@ -10098,6 +10098,23 @@ static bool isVector(QualType QT, QualType
ElementType) {
return false;
}
+bool Sema::IsPointerToPointer(QualType LHSType, QualType RHSType) {
+ if (const PointerType *LHSPointer = dyn_cast(LHSType)) {
erichkeane wrote:
I think
@@ -8265,6 +8265,9 @@ def warn_condition_is_assignment : Warning<"using the
result of an "
def warn_free_nonheap_object
: Warning<"attempt to call %0 on non-heap %select{object %2|object: block
expression|object: lambda-to-function-pointer conversion}1">,
InGroup;
+def
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/80040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
This needs a release note and some tests as well.
https://github.com/llvm/llvm-project/pull/80040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
erichkeane wrote:
> @erichkeane I added the following release note:
>
> > Removed support for constructing on-stack `TemplateArgumentList`s.
> > Interfaces should instead use `ArrayRef` to pass template
> > arguments.
>
> I'm not entirely sure how to benchmark these changes. Perhaps I could
901 - 1000 of 2361 matches
Mail list logo