@@ -53,3 +53,14 @@ alignas(4) auto PR19252 = 0;
// Check the diagnostic message
class alignas(void) AlignasVoid {}; // expected-error {{invalid application of
'alignas' to an incomplete type 'void'}}
+
+namespace GH108819 {
+void a([[maybe_unused]] void) {} //
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/125943
Fixes #125942
>From b2f129874b692bf795136a0f93043ed85ce063d3 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 5 Feb 2025 23:57:09 +0200
Subject: [PATCH] [Clang] refine diagnostic for redundant qualifie
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH 1/7] [Clang] allow restrict qualifier for array types with
poin
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/124920
>From bd731e4be65fc9c1746aa6a8f63d206eb54bb2be Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 29 Jan 2025 15:17:06 +0200
Subject: [PATCH 01/13] [Clang] disallow attributes on void parameters
---
clan
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/124920
>From bd731e4be65fc9c1746aa6a8f63d206eb54bb2be Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 29 Jan 2025 15:17:06 +0200
Subject: [PATCH 01/13] [Clang] disallow attributes on void parameters
---
clan
@@ -0,0 +1,26 @@
+// RUN: %clang_cc1 -std=c23 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -std=c17 -fsyntax-only -pedantic -verify=pedantic %s
+// RUN: %clang_cc1 -std=c17 -fsyntax-only -Wpre-c2x-compat
-verify=pre-c2x-compat %s
+
+typedef int (*T1)[2];
+restrict T1 t1;
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH 1/9] [Clang] allow restrict qualifier for array types with
poin
https://github.com/a-tarasyuk deleted
https://github.com/llvm/llvm-project/pull/120896
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -7409,6 +7409,11 @@ def warn_c23_compat_utf8_string : Warning<
def note_cxx20_c23_compat_utf8_string_remove_u8 : Note<
"remove 'u8' prefix to avoid a change of behavior; "
"Clang encodes unprefixed narrow string literals as UTF-8">;
+def warn_c23_compat_restrict_pointers
@@ -0,0 +1,26 @@
+// RUN: %clang_cc1 -std=c23 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -std=c17 -fsyntax-only -pedantic -verify=pedantic %s
+// RUN: %clang_cc1 -std=c17 -fsyntax-only -Wpre-c2x-compat
-verify=pre-c2x-compat %s
+
+typedef int (*T1)[2];
+restrict T1 t1;
@@ -0,0 +1,26 @@
+// RUN: %clang_cc1 -std=c23 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -std=c17 -fsyntax-only -pedantic -verify=pedantic %s
+// RUN: %clang_cc1 -std=c17 -fsyntax-only -Wpre-c2x-compat
-verify=pre-c2x-compat %s
+
+typedef int (*T1)[2];
+restrict T1 t1;
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH 01/10] [Clang] allow restrict qualifier for array types with
po
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH 01/10] [Clang] allow restrict qualifier for array types with
po
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH 01/10] [Clang] allow restrict qualifier for array types with
po
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/124920
>From bd731e4be65fc9c1746aa6a8f63d206eb54bb2be Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 29 Jan 2025 15:17:06 +0200
Subject: [PATCH 1/3] [Clang] disallow attributes on void parameters
---
clang/
@@ -7986,6 +7986,12 @@ void Parser::ParseParameterDeclarationClause(
if (getLangOpts().HLSL)
MaybeParseHLSLAnnotations(DS.getAttributes());
+if (ParmDeclarator.getDeclarationAttributes().size() &&
a-tarasyuk wrote:
@erichkeane thanks. changed to
@@ -453,3 +453,12 @@ namespace P2361 {
}
alignas(int) struct AlignAsAttribute {}; // expected-error {{misplaced
attributes; expected attributes here}}
+
+namespace GH108819 {
+void a([[maybe_unused]] void) {} // expected-error {{an
attribute list cannot appea
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/124920
>From bd731e4be65fc9c1746aa6a8f63d206eb54bb2be Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 29 Jan 2025 15:17:06 +0200
Subject: [PATCH 1/2] [Clang] disallow attributes on void parameters
---
clang/
@@ -7986,6 +7986,13 @@ void Parser::ParseParameterDeclarationClause(
if (getLangOpts().HLSL)
MaybeParseHLSLAnnotations(DS.getAttributes());
+if (ParmDeclarator.getIdentifier() == nullptr &&
a-tarasyuk wrote:
@cor3ntin thanks for the feedback. I'
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/124920
>From bd731e4be65fc9c1746aa6a8f63d206eb54bb2be Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 29 Jan 2025 15:17:06 +0200
Subject: [PATCH 1/4] [Clang] disallow attributes on void parameters
---
clang/
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/124920
>From bd731e4be65fc9c1746aa6a8f63d206eb54bb2be Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 29 Jan 2025 15:17:06 +0200
Subject: [PATCH 1/4] [Clang] disallow attributes on void parameters
---
clang/
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH 1/3] [Clang] allow restrict qualifier for array types with
poin
@@ -50,8 +50,8 @@ struct testRecoverStrictnessStruct { };
#pragma clang attribute pop
-#pragma clang attribute push (__attribute__((abi_tag("a"))), apply_to =
any(function, record(unless(is_union)), variable, enum))
-// expected-error@-1 {{attribute 'abi_tag' cannot be appli
a-tarasyuk wrote:
@shafik thanks for pointing that out! I'll check it ASAP
https://github.com/llvm/llvm-project/pull/114684
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH 1/2] [Clang] allow restrict qualifier for array types with
poin
a-tarasyuk wrote:
@mydeveloperday would it make sense to close the PR until a final decision
about the feature is made, to avoid unnecessary review effort?
https://github.com/llvm/llvm-project/pull/118566
___
cfe-commits mailing list
cfe-commits@lists
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/115487
>From 5e24d212f797b5fa1b6da1526c807046373d3c21 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 8 Nov 2024 16:13:17 +0200
Subject: [PATCH 1/6] [Clang] skip default argument instantiation for
non-definin
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/118566
>From 75da343b0bd6e3b0f3219b349f6be4c882947820 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 4 Dec 2024 02:24:12 +0200
Subject: [PATCH 1/4] [clang-format] extend clang-format directive with options
t
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/115487
>From 5e24d212f797b5fa1b6da1526c807046373d3c21 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 8 Nov 2024 16:13:17 +0200
Subject: [PATCH 1/6] [Clang] skip default argument instantiation for
non-definin
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/118566
>From 75da343b0bd6e3b0f3219b349f6be4c882947820 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 4 Dec 2024 02:24:12 +0200
Subject: [PATCH 1/5] [clang-format] extend clang-format directive with options
t
@@ -144,7 +144,8 @@ void DefinitionBlockSeparator::separateBlocks(
return false;
if (const auto *Tok = OperateLine->First;
- Tok->is(tok::comment) && !isClangFormatOn(Tok->TokenText)) {
+ Tok->is(tok::comment) && parseClangFormatDirective(Tok->T
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/118566
>From 75da343b0bd6e3b0f3219b349f6be4c882947820 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 4 Dec 2024 02:24:12 +0200
Subject: [PATCH 1/4] [clang-format] extend clang-format directive with options
t
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/115487
>From 5e24d212f797b5fa1b6da1526c807046373d3c21 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 8 Nov 2024 16:13:17 +0200
Subject: [PATCH 1/6] [Clang] skip default argument instantiation for
non-definin
https://github.com/a-tarasyuk closed
https://github.com/llvm/llvm-project/pull/115487
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3307,6 +3307,29 @@ void Sema::CheckShadowInheritedFields(const
SourceLocation &Loc,
}
}
+template
+inline static bool HasAttribute(const QualType &T) {
+ if (const TagDecl *TD = T->getAsTagDecl())
+return TD->hasAttr();
+ if (const TypedefType *TDT = T->getAs())
@@ -3307,6 +3307,29 @@ void Sema::CheckShadowInheritedFields(const
SourceLocation &Loc,
}
}
+template
+inline static bool HasAttribute(const QualType &T) {
+ if (const TagDecl *TD = T->getAsTagDecl())
+return TD->hasAttr();
+ if (const TypedefType *TDT = T->getAs())
@@ -3307,6 +3307,29 @@ void Sema::CheckShadowInheritedFields(const
SourceLocation &Loc,
}
}
+template
+inline static bool HasAttribute(const QualType &T) {
+ if (const TagDecl *TD = T->getAsTagDecl())
+return TD->hasAttr();
+ if (const TypedefType *TDT = T->getAs())
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/120734
Fixes #62472
>From 55fb96c1673911f30721c2a53bea32e7e4b5dc6e Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 20 Dec 2024 15:32:55 +0200
Subject: [PATCH] [Clang] handle [[warn_unused]] attribute for unus
@@ -3307,6 +3307,29 @@ void Sema::CheckShadowInheritedFields(const
SourceLocation &Loc,
}
}
+template
+inline static bool HasAttribute(const QualType &T) {
a-tarasyuk wrote:
@erichkeane Thanks for the detailed feedback. I just extracted this helper
https
https://github.com/a-tarasyuk deleted
https://github.com/llvm/llvm-project/pull/120734
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3307,6 +3307,29 @@ void Sema::CheckShadowInheritedFields(const
SourceLocation &Loc,
}
}
+template
+inline static bool HasAttribute(const QualType &T) {
a-tarasyuk wrote:
@erichkeane Thanks for the detailed feedback. I just extracted this helper
https
https://github.com/a-tarasyuk edited
https://github.com/llvm/llvm-project/pull/120734
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/115487
>From 5e24d212f797b5fa1b6da1526c807046373d3c21 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 8 Nov 2024 16:13:17 +0200
Subject: [PATCH 1/3] [Clang] skip default argument instantiation for
non-definin
@@ -185,3 +185,46 @@ template struct S {
friend void X::f(T::type);
};
}
+
+namespace GH113324 {
+template struct S1 {
+ friend void f1(S1, int = 0); // expected-error {{friend declaration
specifying a default argument must be a definition}}
+ friend void f2(S1 a, S1 = de
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/115487
>From 5e24d212f797b5fa1b6da1526c807046373d3c21 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 8 Nov 2024 16:13:17 +0200
Subject: [PATCH 1/3] [Clang] skip default argument instantiation for
non-definin
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/114684
>From d95d0fdb22ae2ad162f89cb211f313cea6c6474a Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sat, 2 Nov 2024 23:54:35 +0200
Subject: [PATCH 1/7] [Clang] enhance error recovery with RecoveryExpr for
traili
@@ -32,6 +32,25 @@ void test_invalid_call(int s) {
int var = some_func(undef1);
}
+int some_func2(int a, int b);
+void test_invalid_call_2() {
+ // CHECK: -RecoveryExpr {{.*}} 'int' contains-errors
+ // CHECK-NEXT: `-UnresolvedLookupExpr {{.*}} ''
lvalue (ADL) = 'some_f
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/117345
Fixes #116928
>From c3480ca4f4f5b14185880c055613648ceb9f15be Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 22 Nov 2024 18:29:52 +0200
Subject: [PATCH] [Clang] use begin member expression location for
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/106036
>From d4b07c7ff65ca64a5a434818ce09ecd289401340 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Tue, 10 Sep 2024 02:35:43 +0300
Subject: [PATCH] [Clang] restrict use of attribute names reserved by the C++
st
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/117403
Fixes #117385
>From f76ebd39c7ca9761b7812a85a206b63193702c50 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sat, 23 Nov 2024 01:53:29 +0200
Subject: [PATCH] [Clang] skip consumed analysis for consteval con
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/118566
Fixes #54334
>From 8bae39299284dffd592bbf32374929e4a6f2d3ff Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 4 Dec 2024 02:24:12 +0200
Subject: [PATCH] [clang-format] extend clang-format directive with
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/120925
Fixes #120875
>From bce88b1bb464438828fc177c978ad2b99957530f Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 23 Dec 2024 02:35:07 +0200
Subject: [PATCH] [Clang] raise extension warning for unknown nam
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/120896
Fixes #92847
---
> Types other than pointer types whose referenced type is an object type and
> (possibly multi-dimensional) array types with such pointer types as element
> type shall not be restrict-qual
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/122621
Fixes #121706
>From b2c656afdf99eff52d019b68fcbbc6ce4bbdd7d3 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 12 Jan 2025 00:51:47 +0200
Subject: [PATCH] [Clang] disallow the use of asterisks preceding
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/121614
>From b8f6ffc0a98a0d3ac55fba4e6ee680f1edea4571 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sat, 4 Jan 2025 02:24:26 +0200
Subject: [PATCH 1/4] [Clang] disallow attributes after namespace identifier
---
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/106036
>From d4b07c7ff65ca64a5a434818ce09ecd289401340 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Tue, 10 Sep 2024 02:35:43 +0300
Subject: [PATCH 1/6] [Clang] restrict use of attribute names reserved by the
C+
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/122621
>From b2c656afdf99eff52d019b68fcbbc6ce4bbdd7d3 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 12 Jan 2025 00:51:47 +0200
Subject: [PATCH 1/2] [Clang] disallow the use of asterisks preceding
constructo
@@ -10757,6 +10757,17 @@ static void checkMethodTypeQualifiers(Sema &S,
Declarator &D, unsigned DiagID) {
}
}
+static void checkMethodPointerType(Sema &S, Declarator &D, unsigned DiagID) {
+ if (D.getNumTypeObjects() > 0) {
+DeclaratorChunk &Chunk = D.getTypeObject(D.g
@@ -10757,6 +10757,17 @@ static void checkMethodTypeQualifiers(Sema &S,
Declarator &D, unsigned DiagID) {
}
}
+static void checkMethodPointerType(Sema &S, Declarator &D, unsigned DiagID) {
+ if (D.getNumTypeObjects() > 0) {
+DeclaratorChunk &Chunk = D.getTypeObject(D.g
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120734
>From 55fb96c1673911f30721c2a53bea32e7e4b5dc6e Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 20 Dec 2024 15:32:55 +0200
Subject: [PATCH 1/3] [Clang] handle [[warn_unused]] attribute for unused
privat
@@ -3307,6 +3307,29 @@ void Sema::CheckShadowInheritedFields(const
SourceLocation &Loc,
}
}
+template
+inline static bool HasAttribute(const QualType &T) {
+ if (const TagDecl *TD = T->getAsTagDecl())
+return TD->hasAttr();
+ if (const TypedefType *TDT = T->getAs())
@@ -2203,6 +2203,12 @@ Parser::ParseCXXCondition(StmtResult *InitStmt,
SourceLocation Loc,
return ParseCXXCondition(nullptr, Loc, CK, MissingOK);
}
+EnterExpressionEvaluationContext Eval(
a-tarasyuk wrote:
Do you mean using the extra context fo
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/123667
>From 00b8b64879ad3ae35a0a671da563ac876ffaf228 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 20 Jan 2025 22:51:00 +0200
Subject: [PATCH 1/2] [Clang] use constant evaluation context for constexpr if
c
@@ -0,0 +1,10 @@
+// RUN: %clang_cc1 -std=c++26 -verify %s
a-tarasyuk wrote:
@frederick-vs-ja I've updated the test
https://github.com/llvm/llvm-project/pull/123667
___
cfe-commits mailing list
cfe-commits@lists.llvm.o
https://github.com/a-tarasyuk edited
https://github.com/llvm/llvm-project/pull/123667
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2203,6 +2203,12 @@ Parser::ParseCXXCondition(StmtResult *InitStmt,
SourceLocation Loc,
return ParseCXXCondition(nullptr, Loc, CK, MissingOK);
}
+EnterExpressionEvaluationContext Eval(
a-tarasyuk wrote:
This context will be applied only for
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120925
>From bce88b1bb464438828fc177c978ad2b99957530f Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 23 Dec 2024 02:35:07 +0200
Subject: [PATCH 1/4] [Clang] raise extension warning for unknown namespaced
att
https://github.com/a-tarasyuk closed
https://github.com/llvm/llvm-project/pull/121419
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/106036
>From ef0f3551dbb3ce61c57a5ad044d86b504c7742e0 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Tue, 10 Sep 2024 02:35:43 +0300
Subject: [PATCH 1/7] [Clang] restrict use of attribute names reserved by the
C+
a-tarasyuk wrote:
@AaronBallman could you review these changes? thanks
https://github.com/llvm/llvm-project/pull/120896
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120925
>From bce88b1bb464438828fc177c978ad2b99957530f Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 23 Dec 2024 02:35:07 +0200
Subject: [PATCH 1/5] [Clang] raise extension warning for unknown namespaced
att
@@ -1115,6 +1115,11 @@ defm cx_fortran_rules: BoolOptionWithoutMarshalling<"f",
"cx-fortran-rules",
NegFlag>;
+def Wunknown_attribute_namespace_EQ : CommaJoined<["-"],
"Wunknown-attribute-namespace=">,
+ Group, Flags<[HelpHidden]>, Visibility<[ClangOption,
CC1Option]>,
+
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/123667
>From 00b8b64879ad3ae35a0a671da563ac876ffaf228 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 20 Jan 2025 22:51:00 +0200
Subject: [PATCH 1/2] [Clang] use constant evaluation context for constexpr if
c
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH] [Clang] allow restrict qualifier for array types with pointer
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120734
>From 55fb96c1673911f30721c2a53bea32e7e4b5dc6e Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 20 Dec 2024 15:32:55 +0200
Subject: [PATCH 1/3] [Clang] handle [[warn_unused]] attribute for unused
privat
@@ -0,0 +1,100 @@
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -std=c++11 -fsyntax-only -verify
-pedantic %s -DTEST1
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -std=c++11 -fsyntax-only -verify
-pedantic %s -DTEST2
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -std=c++11 -fsynta
https://github.com/a-tarasyuk closed
https://github.com/llvm/llvm-project/pull/106036
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/106036
>From ef0f3551dbb3ce61c57a5ad044d86b504c7742e0 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Tue, 10 Sep 2024 02:35:43 +0300
Subject: [PATCH 1/8] [Clang] restrict use of attribute names reserved by the
C+
@@ -166,7 +166,8 @@ getScopeFromNormalizedScopeName(StringRef ScopeName) {
.Case("hlsl", AttributeCommonInfo::Scope::HLSL)
.Case("msvc", AttributeCommonInfo::Scope::MSVC)
.Case("omp", AttributeCommonInfo::Scope::OMP)
- .Case("riscv", AttributeCommonInfo::
@@ -822,6 +822,7 @@ def NSobjectAttribute : DiagGroup<"NSObject-attribute">;
def NSConsumedMismatch : DiagGroup<"nsconsumed-mismatch">;
def NSReturnsMismatch : DiagGroup<"nsreturns-mismatch">;
+def UnknownAttributeNamespaces : DiagGroup<"unknown-attribute-namespaces">;
def In
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120925
>From bce88b1bb464438828fc177c978ad2b99957530f Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 23 Dec 2024 02:35:07 +0200
Subject: [PATCH 1/8] [Clang] raise extension warning for unknown namespaced
att
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120925
>From bce88b1bb464438828fc177c978ad2b99957530f Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 23 Dec 2024 02:35:07 +0200
Subject: [PATCH 1/9] [Clang] raise extension warning for unknown namespaced
att
@@ -179,13 +179,15 @@ static bool isLanguageDefinedBuiltin(const SourceManager
&SourceMgr,
static bool isReservedCXXAttributeName(Preprocessor &PP, IdentifierInfo *II) {
const LangOptions &Lang = PP.getLangOpts();
if (Lang.CPlusPlus &&
- hasAttribute(AttributeCommonIn
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/106036
>From ef0f3551dbb3ce61c57a5ad044d86b504c7742e0 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Tue, 10 Sep 2024 02:35:43 +0300
Subject: [PATCH 1/7] [Clang] restrict use of attribute names reserved by the
C+
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120734
>From 55fb96c1673911f30721c2a53bea32e7e4b5dc6e Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 20 Dec 2024 15:32:55 +0200
Subject: [PATCH 1/2] [Clang] handle [[warn_unused]] attribute for unused
privat
@@ -3307,6 +3307,29 @@ void Sema::CheckShadowInheritedFields(const
SourceLocation &Loc,
}
}
+template
+inline static bool HasAttribute(const QualType &T) {
a-tarasyuk wrote:
@AaronBallman thanks for the detailed feedback. I've updated the tests to cover
@@ -61,14 +62,23 @@ int clang::hasAttribute(AttributeCommonInfo::Syntax Syntax,
if (res)
return res;
- // Check if any plugin provides this attribute.
- for (auto &Ptr : getAttributePluginInstances())
-if (Ptr->hasSpelling(Syntax, Name))
- return 1;
+ if (Che
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/123667
Fixes #123524
>From 00b8b64879ad3ae35a0a671da563ac876ffaf228 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Mon, 20 Jan 2025 22:51:00 +0200
Subject: [PATCH] [Clang] use constant evaluation context for cons
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/106036
>From ef0f3551dbb3ce61c57a5ad044d86b504c7742e0 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Tue, 10 Sep 2024 02:35:43 +0300
Subject: [PATCH 1/7] [Clang] restrict use of attribute names reserved by the
C+
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/121419
>From 3f6b1d68978857035a972f49b1cfd9d9d0151be9 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 1 Jan 2025 01:47:17 +0200
Subject: [PATCH 1/6] [Clang] emit -Wignored-qualifiers diagnostic for
cv-qualifi
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/121419
>From 3f6b1d68978857035a972f49b1cfd9d9d0151be9 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Wed, 1 Jan 2025 01:47:17 +0200
Subject: [PATCH 1/6] [Clang] emit -Wignored-qualifiers diagnostic for
cv-qualifi
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120734
>From 55fb96c1673911f30721c2a53bea32e7e4b5dc6e Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 20 Dec 2024 15:32:55 +0200
Subject: [PATCH 1/3] [Clang] handle [[warn_unused]] attribute for unused
privat
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH] [Clang] allow restrict qualifier for array types with pointer
https://github.com/a-tarasyuk deleted
https://github.com/llvm/llvm-project/pull/120734
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/a-tarasyuk closed
https://github.com/llvm/llvm-project/pull/120734
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120896
>From 295df258043ef5a87ae603eedd308b863bad7b59 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 22 Dec 2024 15:14:30 +0200
Subject: [PATCH] [Clang] allow restrict qualifier for array types with pointer
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/120734
>From 55fb96c1673911f30721c2a53bea32e7e4b5dc6e Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Fri, 20 Dec 2024 15:32:55 +0200
Subject: [PATCH 1/3] [Clang] handle [[warn_unused]] attribute for unused
privat
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/124920
Fixes #108819
---
This PR introduces diagnostics to disallow the use of attributes on void
parameters
```cpp
void f([[deprecated]] void) {}
```
>From bd731e4be65fc9c1746aa6a8f63d206eb54bb2be Mon Sep 1
https://github.com/a-tarasyuk updated
https://github.com/llvm/llvm-project/pull/122621
>From b2c656afdf99eff52d019b68fcbbc6ce4bbdd7d3 Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sun, 12 Jan 2025 00:51:47 +0200
Subject: [PATCH 1/8] [Clang] disallow the use of asterisks preceding
constructo
@@ -10757,6 +10757,17 @@ static void checkMethodTypeQualifiers(Sema &S,
Declarator &D, unsigned DiagID) {
}
}
+static void checkMethodPointerType(Sema &S, Declarator &D, unsigned DiagID) {
+ if (D.getNumTypeObjects() > 0) {
+DeclaratorChunk &Chunk = D.getTypeObject(D.g
701 - 800 of 1021 matches
Mail list logo