@@ -0,0 +1,72 @@
+//===--- OpenACCKinds.h - OpenACC Enums -*- 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: Apa
@@ -10,18 +10,240 @@
//
//===--===//
+#include "clang/Basic/OpenACCKinds.h"
#include "clang/Parse/ParseDiagnostic.h"
#include "clang/Parse/Parser.h"
+#include "clang/Parse/RAIIObjectsForParser.h"
+#include
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/72661
>From 01fc81b37ad744a265f712b26fd6c3a85430c719 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Fri, 17 Nov 2023 06:29:35 -0800
Subject: [PATCH 1/2] [OpenACC] Implement initial parsing for
Construct/Directive
@@ -3531,7 +3535,7 @@ class Parser : public CodeCompletionHandler {
/// Placeholder for now, should just ignore the directives after emitting a
/// diagnostic. Eventually will be split into a few functions to parse
/// different situations.
- DeclGroupPtrTy ParseOpenACCD
@@ -10,18 +10,240 @@
//
//===--===//
+#include "clang/Basic/OpenACCKinds.h"
#include "clang/Parse/ParseDiagnostic.h"
#include "clang/Parse/Parser.h"
+#include "clang/Parse/RAIIObjectsForParser.h"
+#include
@@ -0,0 +1,72 @@
+//===--- OpenACCKinds.h - OpenACC Enums -*- 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: Apa
erichkeane wrote:
> We will want to have OpenACC label(s) such that people who are interested can
> be notified.
Done, see the next patch in the set here:
https://github.com/llvm/llvm-project/pull/72661
I'll start adding them and see if I can get @llvmbot to teach me how to add it.
https://
@@ -10,18 +10,240 @@
//
//===--===//
+#include "clang/Basic/OpenACCKinds.h"
#include "clang/Parse/ParseDiagnostic.h"
#include "clang/Parse/Parser.h"
+#include "clang/Parse/RAIIObjectsForParser.h"
+#include
@@ -0,0 +1,72 @@
+//===--- OpenACCKinds.h - OpenACC Enums -*- 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: Apa
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/72661
>From 01fc81b37ad744a265f712b26fd6c3a85430c719 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Fri, 17 Nov 2023 06:29:35 -0800
Subject: [PATCH 1/3] [OpenACC] Implement initial parsing for
Construct/Directive
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/72661
___
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/72661
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
erichkeane wrote:
@alexey-bataev : Patch reduced to just parallel as requested.
https://github.com/llvm/llvm-project/pull/72661
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -322,6 +322,73 @@ static Attr *handleUnlikely(Sema &S, Stmt *St, const
ParsedAttr &A,
return ::new (S.Context) UnlikelyAttr(S.Context, A);
}
+CodeAlignAttr *Sema::BuildCodeAlignAttr(const AttributeCommonInfo &CI,
+Expr *E) {
+ if
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/72661
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -322,6 +322,77 @@ static Attr *handleUnlikely(Sema &S, Stmt *St, const
ParsedAttr &A,
return ::new (S.Context) UnlikelyAttr(S.Context, A);
}
+CodeAlignAttr *Sema::BuildCodeAlignAttr(const AttributeCommonInfo &CI,
+Expr *E) {
+ if
@@ -322,6 +322,77 @@ static Attr *handleUnlikely(Sema &S, Stmt *St, const
ParsedAttr &A,
return ::new (S.Context) UnlikelyAttr(S.Context, A);
}
+CodeAlignAttr *Sema::BuildCodeAlignAttr(const AttributeCommonInfo &CI,
+Expr *E) {
+ if
erichkeane wrote:
> Thanks for the review, @erichkeane. I am wondering what you mean by this
> needs "release note"?
Ah, yes! See `docs/ReleaseNotes.rst`. For each new bug fix (and most
patches!) we require an entry into our release notes document.
https://github.com/llvm/llvm-project/pull/
https://github.com/erichkeane created
https://github.com/llvm/llvm-project/pull/72692
This patch implements the compound construct parsing, which allows 'parallel
loop', 'serial loop', and 'kernel loop' to act as their own constructs.
Note that this doesn't end up making any changes to the tes
@@ -322,6 +322,81 @@ static Attr *handleUnlikely(Sema &S, Stmt *St, const
ParsedAttr &A,
return ::new (S.Context) UnlikelyAttr(S.Context, A);
}
+CodeAlignAttr *Sema::BuildCodeAlignAttr(const AttributeCommonInfo &CI,
+Expr *E) {
+ if
@@ -0,0 +1,164 @@
+// RUN: %clang_cc1 -fsyntax-only -verify=expected,c-local -x c %s
+// RUN: %clang_cc1 -fsyntax-only -verify=expected,cpp-local -pedantic -x c++
-std=c++11 %s
+
+void foo() {
+ int i;
+ int a[10], b[10];
+
+ [[clang::code_align(8)]]
+ for (i = 0; i < 10; ++i
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/72692
>From 33ca88871b48fcfb16bdf7fa636a9ecfa4f38e08 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Fri, 17 Nov 2023 11:34:43 -0800
Subject: [PATCH 1/2] [OpenACC] Implement compound construct parsing
This patch im
@@ -50,6 +52,35 @@ OpenACCDirectiveKind ParseOpenACCDirectiveKind(Parser &P) {
if (DirKind == OpenACCDirectiveKind::Invalid)
P.Diag(FirstTok, diag::err_acc_invalid_directive) << FirstTokSpelling;
+ // Combined Constructs allows parallel loop, serial loop, or kernels loo
@@ -45,11 +47,36 @@ OpenACCDirectiveKind ParseOpenACCDirectiveKind(Parser &P) {
P.ConsumeToken();
std::string FirstTokSpelling = P.getPreprocessor().getSpelling(FirstTok);
- OpenACCDirectiveKind DirKind = GetOpenACCDirectiveKind(FirstTokSpelling);
+ OpenACCDirectiveKind
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/72692
>From 33ca88871b48fcfb16bdf7fa636a9ecfa4f38e08 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Fri, 17 Nov 2023 11:34:43 -0800
Subject: [PATCH 1/3] [OpenACC] Implement compound construct parsing
This patch im
@@ -45,11 +47,36 @@ OpenACCDirectiveKind ParseOpenACCDirectiveKind(Parser &P) {
P.ConsumeToken();
std::string FirstTokSpelling = P.getPreprocessor().getSpelling(FirstTok);
- OpenACCDirectiveKind DirKind = GetOpenACCDirectiveKind(FirstTokSpelling);
+ OpenACCDirectiveKind
@@ -4,7 +4,8 @@ void f(T);
template
struct A {
- // expected-error@+1{{cannot declare an explicit specialization in a friend}}
+ // expected-error@+2{{cannot declare an explicit specialization in a friend}}
+ // expected-error@+1{{friend function specialization cannot be de
@@ -373,6 +373,7 @@ template void foo() {} //
expected-note{{candidate ignored: not a memb
}
using ns::foo;
template struct A {
+ // expected-error@+1{{friend function specialization cannot be defined}}
erichkeane wrote:
These already error, and doing a do
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/72863
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
Needs a release note, + this should be replacing errors in the below cases.
https://github.com/llvm/llvm-project/pull/72863
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/
erichkeane wrote:
> Need to add tests
I mentioned in the commit message, that unfortunately this doesn't change
behavior in a way that we can discover in our testing (unless you know how to
check which character a diagnostic was issued on with
`VerifyDiagnosticsConsumer`?). I'd left the test
erichkeane wrote:
> > Need to add tests
>
> I mentioned in the commit message, that unfortunately this doesn't change
> behavior in a way that we can discover in our testing (unless you know how to
> check which character a diagnostic was issued on with
> `VerifyDiagnosticsConsumer`?). I'd le
@@ -45,11 +47,36 @@ OpenACCDirectiveKind ParseOpenACCDirectiveKind(Parser &P) {
P.ConsumeToken();
std::string FirstTokSpelling = P.getPreprocessor().getSpelling(FirstTok);
- OpenACCDirectiveKind DirKind = GetOpenACCDirectiveKind(FirstTokSpelling);
+ OpenACCDirectiveKind
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/72692
>From 33ca88871b48fcfb16bdf7fa636a9ecfa4f38e08 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Fri, 17 Nov 2023 11:34:43 -0800
Subject: [PATCH 1/4] [OpenACC] Implement compound construct parsing
This patch im
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/72692
___
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/70762
___
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/72692
___
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/72346
___
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/72916
These two constructs, 'enter data' and 'exit data', are novel compared to what
is currently in the parser, as this is the first set implemented where the
first token is itself not a valid construct. Because
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/72928
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -91,10 +140,19 @@ OpenACCDirectiveKind ParseOpenACCDirectiveKind(Parser &P) {
P.ConsumeToken();
std::string FirstTokSpelling = P.getPreprocessor().getSpelling(FirstTok);
- OpenACCDirectiveKind DirKind = getOpenACCDirectiveKind(FirstTokSpelling);
+ OpenACCDirectiveKind
@@ -91,10 +140,19 @@ OpenACCDirectiveKind ParseOpenACCDirectiveKind(Parser &P) {
P.ConsumeToken();
std::string FirstTokSpelling = P.getPreprocessor().getSpelling(FirstTok);
- OpenACCDirectiveKind DirKind = getOpenACCDirectiveKind(FirstTokSpelling);
+ OpenACCDirectiveKind
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/72916
>From 5bdbe165e73eea4c01d0a02dec33afdd752a1858 Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Mon, 20 Nov 2023 13:07:55 -0800
Subject: [PATCH 1/2] [OpenACC] Implement enter data/exit data construct
parsing
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/72916
___
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/73015
`atomic` is required to be followed by a special `atomic clause`, so this patch
manages the parsing of that. We are representing each of the variants of the
atomic construct as separate kinds, because they h
https://github.com/erichkeane approved this pull request.
The patch makes sense to me, though my knowledge of this function is limited.
Please give @cor3ntin a chance to look at it too in case he sees something I
don't.
https://github.com/llvm/llvm-project/pull/73018
_
@@ -59,9 +60,21 @@ OpenACCDirectiveKindEx getOpenACCDirectiveKind(StringRef
Name) {
return llvm::StringSwitch(Name)
.Case("enter", OpenACCDirectiveKindEx::Enter)
.Case("exit", OpenACCDirectiveKindEx::Exit)
+ .Case("atomic", OpenACCDirectiveKindEx::Atomic)
@@ -59,9 +60,21 @@ OpenACCDirectiveKindEx getOpenACCDirectiveKind(StringRef
Name) {
return llvm::StringSwitch(Name)
.Case("enter", OpenACCDirectiveKindEx::Enter)
.Case("exit", OpenACCDirectiveKindEx::Exit)
+ .Case("atomic", OpenACCDirectiveKindEx::Atomic)
@@ -94,6 +94,37 @@ void func() {
#pragma acc kernels loop
for(;;){}
+ int i = 0, j = 0, k = 0;
+ // expected-error@+2{{missing OpenACC 'atomic-clause'; expected 'read',
'write', 'update', or 'capture'}}
+ // expected-warning@+1{{OpenACC directives not yet implemented, pr
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/73015
>From e656fb03feeafa1997a4b93126063ad77ecf5b2c Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Tue, 21 Nov 2023 08:56:00 -0800
Subject: [PATCH 1/2] [OpenACC] Implement Atomic construct variants
`atomic` is re
@@ -59,9 +60,21 @@ OpenACCDirectiveKindEx getOpenACCDirectiveKind(StringRef
Name) {
return llvm::StringSwitch(Name)
.Case("enter", OpenACCDirectiveKindEx::Enter)
.Case("exit", OpenACCDirectiveKindEx::Exit)
+ .Case("atomic", OpenACCDirectiveKindEx::Atomic)
@@ -143,26 +139,25 @@ ParseOpenACCEnterExitDataDirective(Parser &P, Token
FirstTok,
: OpenACCDirectiveKind::ExitData;
}
-OpenACCDirectiveKind ParseOpenACCAtomicDirective(Parser &P) {
+OpenACCAtomicKind ParseOpenACCAtomicKind(Parser &P) {
Token AtomicClauseToke
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/73015
___
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/73087
___
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/73143
The 'routine' construct applies either to a function directly, or, when
provided a name, applies to the function named (and is visible in the
current scope). This patch implements the parsing for this. The
ide
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/73143
>From c6b9245f7865a99cd5024fc62aca0f496bcce12b Mon Sep 17 00:00:00 2001
From: erichkeane
Date: Tue, 21 Nov 2023 14:04:41 -0800
Subject: [PATCH 1/2] [OpenACC] Implement 'routine' construct parsing
The 'routine
@@ -232,32 +235,87 @@ void ParseOpenACCClauseList(Parser &P) {
P.Diag(P.getCurToken(),
diag::warn_pragma_acc_unimplemented_clause_parsing);
}
-void ParseOpenACCDirective(Parser &P) {
- OpenACCDirectiveKind DirKind = ParseOpenACCDirectiveKind(P);
+} // namespace
+
+// Rou
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/73143
___
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/73143
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -274,20 +274,27 @@ class DefaultIntArgument :
IntArgument {
}
// This argument is more complex, it includes the enumerator type name,
-// a list of strings to accept, and a list of enumerators to map them to.
-class EnumArgument values,
+// a list of possible values, and a
@@ -3553,6 +3553,56 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`
+// we try to instantiate and update its explicit specifie
@@ -3553,6 +3553,56 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`
+// we try to instantiate and update its explicit specifie
https://github.com/erichkeane commented:
Why doesn't this result in any changes to tests? I would expect having to
remove them, right?
https://github.com/llvm/llvm-project/pull/70632
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lis
erichkeane wrote:
> > Why doesn't this result in any changes to tests? I would expect having to
> > remove them, right?
>
> There was a single test that was relying on sign mismatch, and then during
> code review we made the diagnostic to ignore signness. So it ended up merged
> without test
@@ -5928,28 +5928,6 @@ static void handlePreferredTypeAttr(Sema &S, Decl *D,
const ParsedAttr &AL) {
S.RequireCompleteType(ParmTSI->getTypeLoc().getBeginLoc(), QT,
diag::err_incomplete_type);
- if (QT->isEnumeralType()) {
-auto IsCorrespondingTy
@@ -3553,6 +3553,56 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`
+// we try to instantiate and update its explicit specifie
https://github.com/erichkeane approved this pull request.
This is fine to me, please give other reviewers another day to take a look
before merging though.
https://github.com/llvm/llvm-project/pull/70548
___
cfe-commits mailing list
cfe-commits@lists.
https://github.com/erichkeane commented:
I don't have a good idea how a release note could be phrased here, but if you
could try one, it would be appreciated and I think it is worth doing.
Side note: it would be really cool if at the end of the release cycle, you did
a section in the release-n
@@ -3553,6 +3553,49 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`
+// we try to instantiate and update its explicit specifie
@@ -3553,6 +3553,49 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`
+// we try to instantiate and update its explicit specifie
@@ -3553,6 +3553,49 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`
+// we try to instantiate and update its explicit specifie
@@ -3553,6 +3553,49 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`
+// we try to instantiate and update its explicit specifie
@@ -3580,16 +3580,12 @@ static Sema::TemplateDeductionResult
instantiateExplicitSpecifierDeferred(
if (!Expr->isValueDependent()) {
return Sema::TDK_Success;
}
- // The `InstantiatingTemplate` here is used to restore `ActiveInstType` to
- // `DeducedTemplateArgumentS
@@ -3553,6 +3553,47 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`,
+// we'll try to instantiate and update its explicit spec
@@ -3553,6 +3553,47 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`,
+// we'll try to instantiate and update its explicit spec
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/70548
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
Did a better run-through again, so these are all thats left for me. Thanks for
the patience!
https://github.com/llvm/llvm-project/pull/70548
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://list
@@ -3553,6 +3553,47 @@ static unsigned getPackIndexForParam(Sema &S,
llvm_unreachable("parameter index would not be produced from template");
}
+// if `Specialization` is a `CXXConstructorDecl` or `CXXConversionDecl`,
+// we'll try to instantiate and update its explicit spec
https://github.com/erichkeane approved this pull request.
https://github.com/llvm/llvm-project/pull/70548
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -19,11 +19,12 @@
#include "clang/AST/Type.h"
#include "clang/Basic/AttrKinds.h"
#include "clang/Basic/AttributeCommonInfo.h"
-#include "clang/Basic/LangOptions.h"
#include "clang/Basic/LLVM.h"
+#include "clang/Basic/LangOptions.h"
#include "clang/Basic/OpenMPKinds.h"
#inc
@@ -1010,14 +1022,17 @@ namespace {
// trivial because some enumeration values have multiple named
// enumerators, such as type_visibility(internal) and
// type_visibility(hidden) both mapping to TypeVisibilityAttr::Hidden.
- OS << "const char *" << getAt
@@ -898,23 +898,29 @@ namespace {
}
class EnumArgument : public Argument {
-std::string type;
+std::string fullType;
+StringRef shortType;
std::vector values, enums, uniques;
+bool isExternal;
public:
EnumArgument(const Record &Arg, StringRef
@@ -279,12 +279,13 @@ class DefaultIntArgument :
IntArgument {
// This argument is more complex, it includes the enumerator type name,
// a list of strings to accept, and a list of enumerators to map them to.
-class EnumArgument values,
+class EnumArgument values,
---
erichkeane wrote:
> > I see that the fix is almost ready, good. But generally it would also have
> > helped if the `__has_c_attribute` feature test for this type of borrowed
> > attributes would provide means to distinguish different versions. Here gcc
> > as well as clang only have the value
@@ -279,12 +279,13 @@ class DefaultIntArgument :
IntArgument {
// This argument is more complex, it includes the enumerator type name,
// a list of strings to accept, and a list of enumerators to map them to.
-class EnumArgument values,
+class EnumArgument values,
---
https://github.com/erichkeane commented:
Its a bit of a shame that the `VariadicEnumArgument` isn't being included
here/updated here, I typically appreciate the variadic versions being kept in
sync. But since we don't have a use for it at the moment, I think a 'fixme'
(or a future patch!) wou
@@ -1010,14 +1022,17 @@ namespace {
// trivial because some enumeration values have multiple named
// enumerators, such as type_visibility(internal) and
// type_visibility(hidden) both mapping to TypeVisibilityAttr::Hidden.
- OS << "const char *" << getAt
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/70835
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -930,77 +936,83 @@ namespace {
OS << getLowerName() << "(" << getUpperName() << ")";
}
void writeCtorDefaultInitializers(raw_ostream &OS) const override {
- OS << getLowerName() << "(" << type << "(0))";
+ OS << getLowerName() << "(" << fullType << "(
@@ -1015,7 +1018,8 @@ def ExternalSourceSymbol : InheritableAttr {
def Blocks : InheritableAttr {
let Spellings = [Clang<"blocks">];
- let Args = [EnumArgument<"Type", "BlockType", ["byref"], ["ByRef"]>];
+ let Args = [EnumArgument<"Type", "BlockType",
eri
erichkeane wrote:
> Hi, yes the really bad choice here is by gcc to have the same name for
> basically two different attributes. For the value, they also missed the
> opportunity to do something sensible when moving to C++ attributes, what a
> pitty. For a concrete guideline in that jungle, wh
@@ -898,23 +898,29 @@ namespace {
}
class EnumArgument : public Argument {
-std::string type;
+std::string fullType;
+StringRef shortType;
std::vector values, enums, uniques;
+bool isExternal;
public:
EnumArgument(const Record &Arg, StringRef
https://github.com/erichkeane closed
https://github.com/llvm/llvm-project/pull/70548
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane updated
https://github.com/llvm/llvm-project/pull/70548
>From 11ceaed39b3f0c60c5a44c3b3a2b5856e7ee9a8d Mon Sep 17 00:00:00 2001
From: letrec
Date: Sat, 28 Oct 2023 18:05:36 +0800
Subject: [PATCH 1/7] Defer the instantiation of explicit-specifier after
constraint c
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/65638
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -192,6 +192,13 @@ class AttributeCommonInfo {
bool isC23Attribute() const { return SyntaxUsed == AS_C23; }
+ bool isAlignas() const {
+// In the current state of code, IsAlignas is only configured to return
erichkeane wrote:
This comment is immedia
https://github.com/erichkeane commented:
The comments Aaron made should be fixed, plus 1 more from me, else LGTM.
https://github.com/llvm/llvm-project/pull/65638
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mai
@@ -277,23 +277,28 @@ class DefaultIntArgument :
IntArgument {
int Default = default;
}
-// This argument is more complex, it includes the enumerator type name,
-// a list of strings to accept, and a list of enumerators to map them to.
+// This argument is more complex, it
https://github.com/erichkeane edited
https://github.com/llvm/llvm-project/pull/70835
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/erichkeane commented:
Just 1 more comment (the name of `External` everywhere), else LGTM.
https://github.com/llvm/llvm-project/pull/70835
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/
401 - 500 of 4874 matches
Mail list logo