[clang] [clang-format] Add BreakBeforeTemplateClose option (PR #118046)

2025-01-04 Thread via cfe-commits
leijurv wrote: Ping :pray: https://github.com/llvm/llvm-project/pull/118046 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add LT_RequiresExpression and LT_SimpleRequirement (PR #121681)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes The new line types help to annotate */&/&& in simple requirements as binary operators. Fixes #121675. --- Full diff: https://github.com/llvm/llvm-project/pull/121681.diff 3 Files Affected: - (modified)

[clang] [clang-format] Add LT_RequiresExpression and LT_SimpleRequirement (PR #121681)

2025-01-04 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/121681 The new line types help to annotate */&/&& in simple requirements as binary operators. Fixes #121675. >From bdf0c2e2a9fd78368137e441cc4cad33702fbdc7 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Sat, 4 Jan 202

[clang] [Clang][MIPS] Send correct architecture for MinGW toolchains (PR #121042)

2025-01-04 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `llvm-x86_64-debian-dylib` running on `gribozavr4` while building `clang` at step 7 "test-build-unified-tree-check-llvm". Full details are available at: https://lab.llvm.org/buildbot/#/builders/60/builds/16227 Here is the re

[clang] [emacs][clang-format] Add elisp API for clang-format on git diffs (PR #112792)

2025-01-04 Thread via cfe-commits
goldsteinn wrote: > Checking again and am still considering this patch too spesific/incomplete, > checking vc's diff calls to git - they are considerably more involved than in > this PR, meaning this PR will likely require follow up commits to fix > problems _(see `vc-diff-internal`, inlined b

[clang] [Clang][MIPS] Send correct architecture for MinGW toolchains (PR #121042)

2025-01-04 Thread YunQiang Su via cfe-commits
https://github.com/wzssyqa closed https://github.com/llvm/llvm-project/pull/121042 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8267bea - [Clang][MIPS] Send correct architecture for MinGW toolchains (#121042)

2025-01-04 Thread via cfe-commits
Author: Hervé Poussineau Date: 2025-01-05T15:20:16+08:00 New Revision: 8267bea9a35c3c3f866b942a50c2b98ac462ce35 URL: https://github.com/llvm/llvm-project/commit/8267bea9a35c3c3f866b942a50c2b98ac462ce35 DIFF: https://github.com/llvm/llvm-project/commit/8267bea9a35c3c3f866b942a50c2b98ac462ce35.di

[clang] [clang] Add test for CWG192 "Name lookup in parameters" (PR #121679)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes This patch adds a rather simple test for [CWG192](https://cplusplus.github.io/CWG/issues/192.html). Parameter declarations of member functions are not complete-class contexts (unlike default arguments

[clang] [clang] Add test for CWG192 "Name lookup in parameters" (PR #121679)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/121679 This patch adds a rather simple test for [CWG192](https://cplusplus.github.io/CWG/issues/192.html). Parameter declarations of member functions are not complete-class contexts (unlike default arguments), so the

[clang] Bulk port 64-bit x86 builtins to TableGen (PR #121043)

2025-01-04 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-ppc64-aix` running on `aix-ppc64` while building `clang` at step 3 "clean-build-dir". Full details are available at: https://lab.llvm.org/buildbot/#/builders/64/builds/1883 Here is the relevant piece of the build log f

[clang] [clang] Add test for CWG190 "Layout-compatible POD-struct types" (PR #121668)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll closed https://github.com/llvm/llvm-project/pull/121668 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 267ab1c - [clang] Add test for CWG190 "Layout-compatible POD-struct types" (#121668)

2025-01-04 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2025-01-05T10:29:31+04:00 New Revision: 267ab1cf574bd51d67f3f88c1c4f28a44fca2c8a URL: https://github.com/llvm/llvm-project/commit/267ab1cf574bd51d67f3f88c1c4f28a44fca2c8a DIFF: https://github.com/llvm/llvm-project/commit/267ab1cf574bd51d67f3f88c1c4f28a44fca2c8a.

[clang] [libclang] Add API to query more information about base classes. (PR #120300)

2025-01-04 Thread Trevor Laughlin via cfe-commits
trelau wrote: For what it's worth, to get around my issue in https://github.com/llvm/llvm-project/issues/121502 I followed your same pattern here and added a ```get_methods()``` function to Python (and a new libclang function ```clang_visitCXXMethods```) to access the class methods. Looking a

[clang] [emacs][clang-format] Add elisp API for clang-format on git diffs (PR #112792)

2025-01-04 Thread Campbell Barton via cfe-commits
ideasman42 wrote: Checking again and am still considering this patch too spesific/incomplete, checking vc's diff calls to git - they are considerably more involved than in this PR, meaning this PR will likely require follow up commits to fix problems _(see `vc-diff-internal`, inlined below for

[clang] [clang-format] Add `TT_CompoundRequirementLBrace` for better annotation (PR #121539)

2025-01-04 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/121539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 0093450 - [clang-format] Add `TT_CompoundRequirementLBrace` for better annotation (#121539)

2025-01-04 Thread via cfe-commits
Author: Owen Pan Date: 2025-01-04T20:51:00-08:00 New Revision: 00934505d44e28f3c1d5739d6369648e87f10cf5 URL: https://github.com/llvm/llvm-project/commit/00934505d44e28f3c1d5739d6369648e87f10cf5 DIFF: https://github.com/llvm/llvm-project/commit/00934505d44e28f3c1d5739d6369648e87f10cf5.diff LOG:

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2025-01-04 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-fast` running on `sanitizer-buildbot4` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/169/builds/7054 Here is the relevant piece o

[clang-tools-extra] Add bugprone-undefined-sprintf-overlap (PR #114244)

2025-01-04 Thread Chris Cotter via cfe-commits
ccotter wrote: Thanks both @nicovank @5chmidti for the overlapping reviews. I got sidetracked, but am coming back to hopefully finish this up. Re: supporting more use cases, I found nearly all bugs in our codebase were of the simple form `sprintf(a, "", ..., a, ...)` with a simple DeclRefExpr.

[clang-tools-extra] Add bugprone-undefined-sprintf-overlap (PR #114244)

2025-01-04 Thread Chris Cotter via cfe-commits
@@ -0,0 +1,23 @@ +.. title:: clang-tidy - bugprone-undefined-sprintf-overlap + +bugprone-undefined-sprintf-overlap ccotter wrote: I like this better. I'll change this. https://github.com/llvm/llvm-project/pull/114244 _

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2025-01-04 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 closed https://github.com/llvm/llvm-project/pull/102857 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Add bugprone-undefined-sprintf-overlap (PR #114244)

2025-01-04 Thread Chris Cotter via cfe-commits
ccotter wrote: > 1. How common is this bug? In one of our internal codebases, a sample of about 1500 files found just over 2% of the files had this bug. As we migrated platforms/standard libraries, the behavior which was previously correct (by chance) changed to be incorrect. > 2. What happen

[clang] 96eced6 - [Clang] Implement CWG2369 "Ordering between constraints and substitution" (#102857)

2025-01-04 Thread via cfe-commits
Author: Younan Zhang Date: 2025-01-05T10:50:52+08:00 New Revision: 96eced624e0f120155256033fdcb8342e7e58d6e URL: https://github.com/llvm/llvm-project/commit/96eced624e0f120155256033fdcb8342e7e58d6e DIFF: https://github.com/llvm/llvm-project/commit/96eced624e0f120155256033fdcb8342e7e58d6e.diff

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2025-01-04 Thread Younan Zhang via cfe-commits
zyn0217 wrote: Thanks so much for the review! I'll keep an eye on that PR, and there’s some post-work to do: 1. Cleanup 2. Adaptation for lambdas https://github.com/llvm/llvm-project/pull/102857 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang-tools-extra] Add bugprone-undefined-sprintf-overlap (PR #114244)

2025-01-04 Thread Chris Cotter via cfe-commits
https://github.com/ccotter updated https://github.com/llvm/llvm-project/pull/114244 >From fd914cc82688b122654d2d7ada72007541b197c0 Mon Sep 17 00:00:00 2001 From: Chris Cotter Date: Wed, 30 Oct 2024 10:54:49 -0400 Subject: [PATCH 1/8] Add bugprone-sprintf-overlap --- .../bugprone/BugproneTidyM

[clang-tools-extra] Add bugprone-undefined-sprintf-overlap (PR #114244)

2025-01-04 Thread Chris Cotter via cfe-commits
https://github.com/ccotter updated https://github.com/llvm/llvm-project/pull/114244 >From fd914cc82688b122654d2d7ada72007541b197c0 Mon Sep 17 00:00:00 2001 From: Chris Cotter Date: Wed, 30 Oct 2024 10:54:49 -0400 Subject: [PATCH 1/6] Add bugprone-sprintf-overlap --- .../bugprone/BugproneTidyM

[clang] [Clang] Add GCC's __builtin_stack_address() to Clang. (PR #121332)

2025-01-04 Thread via cfe-commits
https://github.com/aalhwc edited https://github.com/llvm/llvm-project/pull/121332 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add GCC's __builtin_stack_address() to Clang. (PR #121332)

2025-01-04 Thread via cfe-commits
https://github.com/aalhwc updated https://github.com/llvm/llvm-project/pull/121332 >From f247c1ab9fa89ca09476ed0a398a4c4385e75193 Mon Sep 17 00:00:00 2001 From: aalhwc Date: Mon, 30 Dec 2024 05:03:59 -0500 Subject: [PATCH 1/2] [Clang] Add GCC's __builtin_stack_address() to Clang (#82632). Thi

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Nathan Ridge via cfe-commits
@@ -3449,6 +3449,19 @@ Narrowing Matchers +MatcherDependentScopeDeclRefExpr>hasDependentNamestd::string N +Matches the dependent name of a dependent scope decl ref expr. HighCom

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/121656 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 requested changes to this pull request. Thanks for implementing this! The patch looks pretty good, I just have some minor comments and a suggestion for a new test case. https://github.com/llvm/llvm-project/pull/121656 __

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Nathan Ridge via cfe-commits
@@ -2235,6 +2235,21 @@ TEST_P(ASTMatchersTest, ArgumentCountIs_CXXConstructExpr) { Constructor1Arg)); } +TEST_P(ASTMatchersTest, hasDependentName_DependentScopeDeclRefExpr) { + if (!GetParam().isCXX() || GetParam().hasDelayedTemplateParsing()) { +// FIXM

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Nathan Ridge via cfe-commits
@@ -2235,6 +2235,21 @@ TEST_P(ASTMatchersTest, ArgumentCountIs_CXXConstructExpr) { Constructor1Arg)); } +TEST_P(ASTMatchersTest, hasDependentName_DependentScopeDeclRefExpr) { HighCommander4 wrote: nit: looking at other tests in this file, th

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Nathan Ridge via cfe-commits
@@ -3257,6 +3257,17 @@ AST_MATCHER_P(CXXDependentScopeMemberExpr, memberHasSameNameAsBoundNode, }); } +/// Matches the dependent name of a dependent scope decl ref expr HighCommander4 wrote: likewise here, "of a DependentScopeDeclRefExpr" https://gith

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Nathan Ridge via cfe-commits
@@ -1116,6 +1116,8 @@ AST Matchers - Add ``dependentTemplateSpecializationType`` matcher to match a dependent template specialization type. +- Add ``hasDependentName`` matcher to match the dependent name of a dependent scope decl ref expr. HighCommander4 wr

[clang] Bulk port 64-bit x86 builtins to TableGen (PR #121043)

2025-01-04 Thread Chandler Carruth via cfe-commits
https://github.com/chandlerc closed https://github.com/llvm/llvm-project/pull/121043 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] a774adb - Bulk port 64-bit x86 builtins to TableGen (#121043)

2025-01-04 Thread via cfe-commits
Author: Chandler Carruth Date: 2025-01-04T17:52:19-08:00 New Revision: a774adb017256ceae85ec92ce5148ed47e517540 URL: https://github.com/llvm/llvm-project/commit/a774adb017256ceae85ec92ce5148ed47e517540 DIFF: https://github.com/llvm/llvm-project/commit/a774adb017256ceae85ec92ce5148ed47e517540.di

[clang] [clang-format] Add `TT_CompoundRequirementLBrace` for better annotation (PR #121539)

2025-01-04 Thread Emilia Kond via cfe-commits
https://github.com/rymiel approved this pull request. #121675 https://github.com/llvm/llvm-project/pull/121539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Bulk port 64-bit x86 builtins to TableGen (PR #121043)

2025-01-04 Thread Chandler Carruth via cfe-commits
https://github.com/chandlerc edited https://github.com/llvm/llvm-project/pull/121043 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [emacs][clang-format] Add elisp API for clang-format on git diffs (PR #112792)

2025-01-04 Thread via cfe-commits
goldsteinn wrote: ping @ideasman42 or @lukel97 https://github.com/llvm/llvm-project/pull/112792 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add TT_AfterPPDirective for better annotation (PR #121622)

2025-01-04 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/121622 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Don't break short macro call followed by l_paren (PR #121626)

2025-01-04 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/121626 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] c1ea05e - [clang-format] Don't break short macro call followed by l_paren (#121626)

2025-01-04 Thread via cfe-commits
Author: Owen Pan Date: 2025-01-04T16:24:41-08:00 New Revision: c1ea05eaf0fbe4b539952689dbf9f0df716c72e7 URL: https://github.com/llvm/llvm-project/commit/c1ea05eaf0fbe4b539952689dbf9f0df716c72e7 DIFF: https://github.com/llvm/llvm-project/commit/c1ea05eaf0fbe4b539952689dbf9f0df716c72e7.diff LOG:

[clang] 44b83e8 - [clang-format] Add TT_AfterPPDirective for better annotation (#121622)

2025-01-04 Thread via cfe-commits
Author: Owen Pan Date: 2025-01-04T16:22:54-08:00 New Revision: 44b83e81b5a48d543bf718907f00a21179ec03a4 URL: https://github.com/llvm/llvm-project/commit/44b83e81b5a48d543bf718907f00a21179ec03a4 DIFF: https://github.com/llvm/llvm-project/commit/44b83e81b5a48d543bf718907f00a21179ec03a4.diff LOG:

[clang] [clang] Add test for CWG190 "Layout-compatible POD-struct types" (PR #121668)

2025-01-04 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. saying clang 19 is very weird as this probably always worked, but lgtm otherwise https://github.com/llvm/llvm-project/pull/121668 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://

[clang] [clang-format][NFC] Replace SmallVectorImpl with ArrayRef (PR #121621)

2025-01-04 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/121621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 04610b9 - [clang-format][NFC] Replace SmallVectorImpl with ArrayRef (#121621)

2025-01-04 Thread via cfe-commits
Author: Owen Pan Date: 2025-01-04T16:19:46-08:00 New Revision: 04610b901f41c4abec169b9a38f1b0a2fde976c1 URL: https://github.com/llvm/llvm-project/commit/04610b901f41c4abec169b9a38f1b0a2fde976c1 DIFF: https://github.com/llvm/llvm-project/commit/04610b901f41c4abec169b9a38f1b0a2fde976c1.diff LOG:

[clang] 66f16e6 - [clang-format][NFC] Add missing config tests for List of Strings (#121451)

2025-01-04 Thread via cfe-commits
Author: Owen Pan Date: 2025-01-04T16:14:25-08:00 New Revision: 66f16e682f84551552099a45e608fa260b14e3ab URL: https://github.com/llvm/llvm-project/commit/66f16e682f84551552099a45e608fa260b14e3ab DIFF: https://github.com/llvm/llvm-project/commit/66f16e682f84551552099a45e608fa260b14e3ab.diff LOG:

[clang] [clang-format][NFC] Add missing config tests for List of Strings (PR #121451)

2025-01-04 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/121451 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++] implement views::concat (PR #120920)

2025-01-04 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/120920 error: too big or took too long to generate ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [clang-format][NFC] Replace SmallVectorImpl with ArrayRef (PR #121621)

2025-01-04 Thread via cfe-commits
https://github.com/mydeveloperday approved this pull request. https://github.com/llvm/llvm-project/pull/121621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add `TT_CompoundRequirementLBrace` for better annotation (PR #121539)

2025-01-04 Thread via cfe-commits
https://github.com/mydeveloperday approved this pull request. https://github.com/llvm/llvm-project/pull/121539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++] implement views::concat (PR #120920)

2025-01-04 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/120920 error: too big or took too long to generate ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [clang-format] Add TT_AfterPPDirective for better annotation (PR #121622)

2025-01-04 Thread via cfe-commits
https://github.com/mydeveloperday approved this pull request. https://github.com/llvm/llvm-project/pull/121622 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Don't break short macro call followed by l_paren (PR #121626)

2025-01-04 Thread via cfe-commits
https://github.com/mydeveloperday approved this pull request. https://github.com/llvm/llvm-project/pull/121626 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++] implement views::concat (PR #120920)

2025-01-04 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/120920 error: too big or took too long to generate ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] Add an off-by-default warning to complain about MSVC bitfield padding (PR #117428)

2025-01-04 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt updated https://github.com/llvm/llvm-project/pull/117428 >From 3e25d7ef2e223942298078dace8979905956d05c Mon Sep 17 00:00:00 2001 From: Oliver Hunt Date: Fri, 22 Nov 2024 17:53:24 +0100 Subject: [PATCH 1/7] Add an off-by-default warning to complain about MSVC bitfield

[clang] [llvm] [HLSL][SPIR-V] implement SV_GroupID semantic lowering (PR #121521)

2025-01-04 Thread Zhengxing li via cfe-commits
https://github.com/lizhengxing closed https://github.com/llvm/llvm-project/pull/121521 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 7a76110 - [HLSL][SPIR-V] implement SV_GroupID semantic lowering (#121521)

2025-01-04 Thread via cfe-commits
Author: Zhengxing li Date: 2025-01-04T14:02:39-08:00 New Revision: 7a761100960c0c9e2b2fa8a9ee233b137270bd73 URL: https://github.com/llvm/llvm-project/commit/7a761100960c0c9e2b2fa8a9ee233b137270bd73 DIFF: https://github.com/llvm/llvm-project/commit/7a761100960c0c9e2b2fa8a9ee233b137270bd73.diff

[clang] [clang] Add test for CWG190 "Layout-compatible POD-struct types" (PR #121668)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/121668 This patch adds test for [CWG190](https://cplusplus.github.io/CWG/issues/190.html), leveraging `__is_layout_compatible` intrinsic added for C++20 `std::is_layout_compatible`. I conservatively set the status to

[clang] [clang] Add test for CWG190 "Layout-compatible POD-struct types" (PR #121668)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes This patch adds test for [CWG190](https://cplusplus.github.io/CWG/issues/190.html), leveraging `__is_layout_compatible` intrinsic added for C++20 `std::is_layout_compatible`. I conservatively set the

[clang] [clang] Add test for CWG170 "Pointer-to-member conversions" (PR #121667)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/121667 This patch adds test for [CWG170](https://cplusplus.github.io/CWG/issues/170.html). The resolution adds explicit undefined behavior, so I think the best we can do is to put the test into constexpr evaluator. C

[clang] [clang] Add test for CWG170 "Pointer-to-member conversions" (PR #121667)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes This patch adds test for [CWG170](https://cplusplus.github.io/CWG/issues/170.html). The resolution adds explicit undefined behavior, so I think the best we can do is to put the test into constexpr eva

[clang] [llvm] [llvm][NFC] Rework Timer.cpp globals to ensure valid lifetimes (PR #121663)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: None (macurtis-amd) Changes This is intended to help with flang `-ftime-report` support: - #107270. With this change, I was able to cherry-pick #107270, uncomment `llvm::TimePassesIsEnabled = true;` and compile with `-ftime-report`

[clang] [llvm] [llvm][NFC] Rework Timer.cpp globals to ensure valid lifetimes (PR #121663)

2025-01-04 Thread via cfe-commits
https://github.com/macurtis-amd created https://github.com/llvm/llvm-project/pull/121663 This is intended to help with flang `-ftime-report` support: - #107270. With this change, I was able to cherry-pick #107270, uncomment `llvm::TimePassesIsEnabled = true;` and compile with `-ftime-report`.

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2025-01-04 Thread Oliver Hunt via cfe-commits
ojhunt wrote: > (while too lazy to godbolt right now) Given I basically wrote the entire example, I thought I would just do the godbolting, and lo ```cpp enum class Enum { A, B, C, D }; struct S { Enum e: 1; // I'm a rockstar developer and "know" that I'll only ever assign A or B here };

[clang] [clang-format][NFC] Add missing config tests for List of Strings (PR #121451)

2025-01-04 Thread Owen Pan via cfe-commits
owenca wrote: > these tests are so inconsistent but I guess it's not that critical See the added commit message. https://github.com/llvm/llvm-project/pull/121451 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[clang] [clang-format][NFC] Add missing config tests for List of Strings (PR #121451)

2025-01-04 Thread Owen Pan via cfe-commits
https://github.com/owenca edited https://github.com/llvm/llvm-project/pull/121451 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2025-01-04 Thread Oliver Hunt via cfe-commits
ojhunt wrote: > > and I thought making just preferred_type warnings early would be especially > > insane :D > > I don't necessarily agree. `preferred_type` is a relatively new thing, so we > can try doing something new here. > Yeah, but the implementation is essentially identical, so I would

[clang] [clang-format] Add `TT_CompoundRequirementLBrace` for better annotation (PR #121539)

2025-01-04 Thread Owen Pan via cfe-commits
owenca wrote: > This is a good fix but I think it might not be addressing the whole issue. > This isn't a problem with just _compound-requirement_, it's the case for > _simple-requirement_s too. This patch fixes compound requirements as mentioned in the commit message and reported in the GitH

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: > and I thought making just preferred_type warnings early would be especially > insane :D I don't necessarily agree. `preferred_type` is a relatively new thing, so we can try doing something new here. > [edit: I just realized even that might need to be an option because I can

[clang] [clang] Add test for CWG794 "Base-derived conversion in member type of pointer-to-member conversion" (PR #121660)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes This patch adds a test for [CWG794](https://cplusplus.github.io/CWG/issues/794.html), which is an NB comment closed as NAD. Author was asked to bring a paper to Evolution, which never happened. So we

[clang] [clang] Add test for CWG794 "Base-derived conversion in member type of pointer-to-member conversion" (PR #121660)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/121660 This patch adds a test for [CWG794](https://cplusplus.github.io/CWG/issues/794.html), which is an NB comment closed as NAD. Author was asked to bring a paper to Evolution, which never happened. So we test for

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2025-01-04 Thread Oliver Hunt via cfe-commits
ojhunt wrote: > Looking at diagnostics in the test you add, I wonder why don't we issue them, > and especially the fixit, when we parse bit-field declaration. Why waiting > until assignment happens? Yeah, it's super frustrating to me that we do that - I did _consider_ making them early but I

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: Looking at diagnostics in the test you add, I wonder why don't we issue them, and especially the fixit, when we parse bit-field declaration. Why waiting until assignment happens? https://github.com/llvm/llvm-project/pull/116785 ___ cfe

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2025-01-04 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt updated https://github.com/llvm/llvm-project/pull/116785 >From 5f260726253e78a00d2dff02c22837ce02b49075 Mon Sep 17 00:00:00 2001 From: Oliver Hunt Date: Tue, 19 Nov 2024 11:55:11 +0100 Subject: [PATCH 1/6] [Clang] Consider preferred_type in bitfield warnings (#116760)

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2025-01-04 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt updated https://github.com/llvm/llvm-project/pull/116785 >From 5f260726253e78a00d2dff02c22837ce02b49075 Mon Sep 17 00:00:00 2001 From: Oliver Hunt Date: Tue, 19 Nov 2024 11:55:11 +0100 Subject: [PATCH 1/5] [Clang] Consider preferred_type in bitfield warnings (#116760)

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Amr Hesham (AmrDeveloper) Changes Add the `hasDependentName` matcher to match the name of `DependentScopeDeclRefExpr` Example: `dependentScopeDeclRefExpr(hasDependentName("name"))` Fixes: #121610 --- Full diff: https://github.com/llvm/l

[clang] [Clang][ASTMatcher] Add a matcher for the name of a DependentScopeDeclRefExpr (PR #121656)

2025-01-04 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/121656 Add the `hasDependentName` matcher to match the name of `DependentScopeDeclRefExpr` Example: `dependentScopeDeclRefExpr(hasDependentName("name"))` Fixes: #121610 >From 4cd48886384570e0e5bb0b712f4fd45f8de

[clang] [clang] Add test for CWG156 "Name lookup for conversion functions" (PR #121654)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes This patch adds test for [CWG156](https://cplusplus.github.io/CWG/issues/156.html). The most relevant piece of current wording is [[basic.lookup.unqual]/5](https://eel.is/c++draft/basic.lookup#unqual-

[clang] [clang] Add test for CWG156 "Name lookup for conversion functions" (PR #121654)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/121654 This patch adds test for [CWG156](https://cplusplus.github.io/CWG/issues/156.html). The most relevant piece of current wording is [[basic.lookup.unqual]/5](https://eel.is/c++draft/basic.lookup#unqual-5): > An

[clang] [Clang][Headers] Workaround for UCRT's `` in `` (PR #121650)

2025-01-04 Thread A. Jiang via cfe-commits
https://github.com/frederick-vs-ja edited https://github.com/llvm/llvm-project/pull/121650 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Headers] Workaround for UCRT's `` in `` (PR #121650)

2025-01-04 Thread A. Jiang via cfe-commits
@@ -28,6 +28,30 @@ #define _TG_ATTRSp __attribute__((__overloadable__)) #define _TG_ATTRS __attribute__((__overloadable__, __always_inline__)) +// https://github.com/llvm/llvm-project/issues/45552 +// workaround for MS UCRT's +#if defined(_VCRUNTIME_H) && defined(_C_COMPLEX_T

[clang] [clang] Restrict use of scalar types in vector builtins (PR #119423)

2025-01-04 Thread Dale Kim via cfe-commits
@@ -68,15 +66,18 @@ void test_builtin_elementwise_add_sat(float f1, float f2, double d1, double d2, long long int i2, si8 vi1, si8 vi2, unsigned u1, unsigned u2, u4 vu1, u4 vu2,

[clang] [Clang][Headers] Workaround for UCRT's `` in `` (PR #121650)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-x86 @llvm/pr-subscribers-clang Author: A. Jiang (frederick-vs-ja) Changes This patch uses `__builtin_bit_cast` as workaround to make MS UCRT's non-conforming functions `` usable for ``. Fixes #45552. --- Patch is 21.02 Ki

[clang] [Clang][Headers] Workaround for UCRT's `` in `` (PR #121650)

2025-01-04 Thread A. Jiang via cfe-commits
https://github.com/frederick-vs-ja created https://github.com/llvm/llvm-project/pull/121650 This patch uses `__builtin_bit_cast` as workaround to make MS UCRT's non-conforming functions `` usable for ``. Fixes #45552. >From 0366072ca42ec9773897daabf7946eb37c631623 Mon Sep 17 00:00:00 2001 Fro

[clang] [clang-tools-extra] [compiler-rt] [clang-tidy] add `ctime` and `localtime` to `clang-tidy` (PR #110366)

2025-01-04 Thread via cfe-commits
=?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0J

[clang] [clang-tools-extra] [compiler-rt] [clang-tidy] add `ctime` and `localtime` to `clang-tidy` (PR #110366)

2025-01-04 Thread via cfe-commits
=?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf

[clang] [clang-tools-extra] [compiler-rt] [clang-tidy] add `ctime` and `localtime` to `clang-tidy` (PR #110366)

2025-01-04 Thread via cfe-commits
=?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf

[clang] [clang-tools-extra] [compiler-rt] [clang-tidy] add `ctime` and `localtime` to `clang-tidy` (PR #110366)

2025-01-04 Thread via cfe-commits
=?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw==?=, =?utf

[clang] [clang-tools-extra] [compiler-rt] [clang-tidy] add `ctime` and `localtime` to `clang-tidy` (PR #110366)

2025-01-04 Thread via cfe-commits
=?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0JfQuNGI0LDQvSDQnNC40YDQtw=?=, =?utf-8?b?0J

[clang] [clang] Update C++ DR status page (PR #121642)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll closed https://github.com/llvm/llvm-project/pull/121642 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] da2a9ed - [clang] Update C++ DR status page (#121642)

2025-01-04 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2025-01-04T18:53:01+04:00 New Revision: da2a9ede81a88bea0bba28a543441197772e4727 URL: https://github.com/llvm/llvm-project/commit/da2a9ede81a88bea0bba28a543441197772e4727 DIFF: https://github.com/llvm/llvm-project/commit/da2a9ede81a88bea0bba28a543441197772e4727.

[clang] [clang-format][NFC] Add missing config tests for List of Strings (PR #121451)

2025-01-04 Thread Emilia Kond via cfe-commits
https://github.com/rymiel approved this pull request. these tests are so inconsistent but I guess it's not that critical https://github.com/llvm/llvm-project/pull/121451 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [clang-format] Add `TT_CompoundRequirementLBrace` for better annotation (PR #121539)

2025-01-04 Thread Emilia Kond via cfe-commits
rymiel wrote: This is a good fix but I think it might not be addressing the whole issue. This isn't a problem with just *compound-requirement*, it's the case for *simple-requirement*s too. This is valid: ```c++ template concept Multiplicable = requires(T a, T b) { a * b; }; ``` but clang-form

[clang] [clang] Update C++ DR status page (PR #121642)

2025-01-04 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. https://github.com/llvm/llvm-project/pull/121642 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Mechanically port bulk of x86 builtins to TableGen (PR #120831)

2025-01-04 Thread Phoebe Wang via cfe-commits
@@ -108,9 +109,15 @@ class PrototypeParser { } else if (T.consume_back("&")) { ParseType(T); Type += "&"; +} else if (T.consume_front("long long")) { phoebewang wrote: Thanks for the information! https://github.com/llvm/llvm-project/pull/1

[clang] Bulk port 64-bit x86 builtins to TableGen (PR #121043)

2025-01-04 Thread Phoebe Wang via cfe-commits
https://github.com/phoebewang approved this pull request. LGTM, thanks! https://github.com/llvm/llvm-project/pull/121043 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Update C++ DR status page (PR #121642)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/121642 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Update C++ DR status page (PR #121642)

2025-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes This patch brings our C++ DR status page up to date with WG21 updates. [CWG1223](https://cplusplus.github.io/CWG/issues/1223.html) "Syntactic disambiguation and _trailing-return-types_" is resolved by

[clang] [clang] Update C++ DR status page (PR #121642)

2025-01-04 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/121642 This patch brings our C++ DR status page up to date with WG21 updates. [CWG1223](https://cplusplus.github.io/CWG/issues/1223.html) "Syntactic disambiguation and _trailing-return-types_" is resolved by [P2915R0

  1   2   >