[clang-tools-extra] [modularize] Use std::tie to implement operator< (NFC) (PR #146220)

2025-06-28 Thread Shilei Tian via cfe-commits
https://github.com/shiltian approved this pull request. https://github.com/llvm/llvm-project/pull/146220 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] clang_EvalResult_getAsCXString impl (PR #134551)

2025-06-28 Thread Damian Andrei via cfe-commits
https://github.com/xTachyon edited https://github.com/llvm/llvm-project/pull/134551 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] clang_EvalResult_getAsCXString impl (PR #134551)

2025-06-28 Thread Damian Andrei via cfe-commits
@@ -44,6 +45,11 @@ typedef struct { unsigned Count; } CXStringSet; +typedef struct { + const char *string; + size_t length; +} CStringInfo; xTachyon wrote: Should we love space for possible expansion? https://github.com/llvm/llvm-project/pull/134551

[clang] clang_EvalResult_getAsCXString impl (PR #134551)

2025-06-28 Thread Damian Andrei via cfe-commits
https://github.com/xTachyon updated https://github.com/llvm/llvm-project/pull/134551 >From 6d8d8955c1e3c706e3195e440f9435e5ae197f9f Mon Sep 17 00:00:00 2001 From: Andrei Damian Date: Sun, 6 Apr 2025 19:55:59 +0300 Subject: [PATCH] clang_EvalResult_getAsCXString impl --- clang/include/clang-c/

[clang] [clang][Sema] Suggest/Hint Standard Library Include File (PR #146227)

2025-06-28 Thread via cfe-commits
https://github.com/Mr-Anyone converted_to_draft https://github.com/llvm/llvm-project/pull/146227 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Mips] Correctly define IntPtrType (PR #145158)

2025-06-28 Thread Hervé Poussineau via cfe-commits
hpoussin wrote: Ping https://github.com/llvm/llvm-project/pull/145158 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Mips] Correctly define IntPtrType (PR #145158)

2025-06-28 Thread Hervé Poussineau via cfe-commits
hpoussin wrote: Ping https://github.com/llvm/llvm-project/pull/145158 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Sema] Suggest/Hint Standard Library Include File (PR #146227)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-modules Author: Vincent (Mr-Anyone) Changes Clang now tries to suggest and hint standard library include file by emitting the following. ``` 4 | std::unordered_map map; | ^ main.cpp:4:1

[clang] [clang][Sema] Suggest/Hint Standard Library Include File (PR #146227)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vincent (Mr-Anyone) Changes Clang now tries to suggest and hint standard library include file by emitting the following. ``` 4 | std::unordered_map map; | ^ main.cpp:4:10: note:

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread via cfe-commits
@@ -2374,6 +2374,9 @@ static bool FinishForRangeVarDecl(Sema &SemaRef, VarDecl *Decl, Expr *Init, SemaRef.ObjC().inferObjCARCLifetime(Decl)) Decl->setInvalidDecl(); + if (SemaRef.getLangOpts().CPlusPlus23) yronglin wrote: I think we don't need thi

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread via cfe-commits
@@ -1341,6 +1342,13 @@ checkExprLifetimeImpl(Sema &SemaRef, const InitializedEntity *InitEntity, } if (IsGslPtrValueFromGslTempOwner && DiagLoc.isValid()) { + +if (SemaRef.getLangOpts().CPlusPlus23) { + if (const VarDecl *VD = cast(InitEntity->get

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread via cfe-commits
@@ -57,6 +57,7 @@ enum LifetimeKind { }; using LifetimeResult = llvm::PointerIntPair; + yronglin wrote: Nit: Let's revert blank modification. https://github.com/llvm/llvm-project/pull/145164 ___ cfe-commits mail

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread via cfe-commits
@@ -1584,6 +1589,20 @@ class VarDecl : public DeclaratorDecl, public Redeclarable { NonParmVarDeclBits.IsCXXCondDecl = true; } + /// Determine whether this variable is the compiler-generated '__range' yronglin wrote: ```suggestion /// Whether this v

[clang] [C][Parser] Diagnostic for attribute declaration where statement is required (PR #146224)

2025-06-28 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff HEAD~1 HEAD --extensions h,c,cpp -- clang/test/Sema/c2x-fallthrough2.c clang/test/Sem

[clang] [C][Parser] Diagnostic for attribute declaration where statement is required (PR #146224)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (yronglin) Changes Fixes: https://github.com/llvm/llvm-project/issues/141659 In C23, something like [[/*possible attributes*/]]; is an attribute declaration, not a statement. So it is not allowed by the syntax in places where a stat

[clang] [C][Parser] Diagnostic for attribute declaration where statement is required (PR #146224)

2025-06-28 Thread via cfe-commits
https://github.com/yronglin created https://github.com/llvm/llvm-project/pull/146224 Fixes: https://github.com/llvm/llvm-project/issues/141659 In C23, something like [[/*possible attributes*/]]; is an attribute declaration, not a statement. So it is not allowed by the syntax in places where a

[clang-tools-extra] [modularize] Use std::tie to implement operator< (NFC) (PR #146220)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: Kazu Hirata (kazutakahirata) Changes std::tie clearly expresses the intent while slightly shortening the code. --- Full diff: https://github.com/llvm/llvm-project/pull/146220.diff 1 Files Affected: - (modified) clang-tools-

[clang-tools-extra] [modularize] Use std::tie to implement operator< (NFC) (PR #146220)

2025-06-28 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/146220 std::tie clearly expresses the intent while slightly shortening the code. >From 5a7e851dd568fe212ad0d497b3b090318cfc8857 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Fri, 27 Jun 2025 22:10:27 -0700

[clang] [llvm] [mlir] [debuginfo][coro] Emit debug info labels for coroutine resume points (PR #141937)

2025-06-28 Thread Adrian Vogelsgesang via cfe-commits
https://github.com/vogelsgesang updated https://github.com/llvm/llvm-project/pull/141937 >From 185be04e482344ce2f76eeb02859162e1838150e Mon Sep 17 00:00:00 2001 From: Adrian Vogelsgesang Date: Tue, 27 May 2025 19:36:42 + Subject: [PATCH 1/5] [debuginfo][coro] Emit debug info labels for coro

[clang] [CIR] Upstream GenericSelectionExpr (PR #146211)

2025-06-28 Thread Henrich Lauko via cfe-commits
https://github.com/xlauko approved this pull request. lgtm https://github.com/llvm/llvm-project/pull/146211 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream GenericSelectionExpr (PR #146211)

2025-06-28 Thread Henrich Lauko via cfe-commits
https://github.com/xlauko edited https://github.com/llvm/llvm-project/pull/146211 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Hexagon] NFC: Reduce the amount of version-specific code (PR #145812)

2025-06-28 Thread Brian Cain via cfe-commits
androm3da wrote: @quic-akaryaki maybe this would fix the `MemorySanitizer: use-of-uninitialized-value`? ``` diff --git a/llvm/lib/Target/Hexagon/HexagonSubtarget.cpp b/llvm/lib/Target/Hexagon/HexagonSubtarget.cpp index ecc1b5d2ebe3..5e92ee284769 100644 --- a/llvm/lib/Target/Hexagon/HexagonSubt

[clang] [clang-format] Fix a bug in `ReflowComments: Always` (PR #146202)

2025-06-28 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request. https://github.com/llvm/llvm-project/pull/146202 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ExtractAPI] Format pointer types correctly (PR #146182)

2025-06-28 Thread Prajwal Nadig via cfe-commits
https://github.com/snprajwal edited https://github.com/llvm/llvm-project/pull/146182 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ExtractAPI] Format pointer types correctly (PR #146182)

2025-06-28 Thread Prajwal Nadig via cfe-commits
https://github.com/snprajwal edited https://github.com/llvm/llvm-project/pull/146182 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ExtractAPI] Format pointers in params correctly (PR #146182)

2025-06-28 Thread Prajwal Nadig via cfe-commits
https://github.com/snprajwal updated https://github.com/llvm/llvm-project/pull/146182 >From 398c55dd352e0f38f5dc5b85a9f6dca836706597 Mon Sep 17 00:00:00 2001 From: Prajwal Nadig Date: Sat, 28 Jun 2025 01:33:42 +0100 Subject: [PATCH] [ExtractAPI] Format pointer types correctly Pointer types in

[clang] [llvm] [mlir] [debuginfo][coro] Emit debug info labels for coroutine resume points (PR #141937)

2025-06-28 Thread Felipe de Azevedo Piovezan via cfe-commits
felipepiovezan wrote: > ~Note that this also influences Swift. The new labels will also be available > in Swift. I hope this might also be useful for Swift to improve debugging > experience, and hence is actually a good thing?~ > > > > ~Not sure, though. If you want, I could also skip emitti

[clang] [llvm] [mlir] [debuginfo][coro] Emit debug info labels for coroutine resume points (PR #141937)

2025-06-28 Thread Adrian Vogelsgesang via cfe-commits
vogelsgesang wrote: Note that this also influences Swift. The new labels will also be available in Swift. I hope this might also be useful for Swift to improve debugging experience, and hence is actually a good thing? Not sure, though. If you want, I could also skip emitting those labels for

[clang] [analyzer] Avoid unnecessary super region invalidation in `CStringChecker` (PR #146212)

2025-06-28 Thread via cfe-commits
https://github.com/flovent edited https://github.com/llvm/llvm-project/pull/146212 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Avoid unnecessary super region invalidation in `CStringChecker` (PR #146212)

2025-06-28 Thread via cfe-commits
https://github.com/flovent edited https://github.com/llvm/llvm-project/pull/146212 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][analyzer] Fix the false positive ArgInitializedness warning on unnamed bit-field (PR #145066)

2025-06-28 Thread via cfe-commits
Tedlion wrote: @steakhal I've reverted my change in RegionStore.cpp, since now I realize it is more complicated than I thought. Considring the costum copy construction and direct memory operations(such as the memset), simply considering the unnamed bit-field is an UndefinedVal may be wrong , e

[clang] [analyzer] Avoid unnecessary super region invalidation in `CStringChecker` (PR #146212)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: None (flovent) Changes Bounded string functions takes smallest of two values as it's copy size (`amountCopied` variable in `evalStrcpyCommon`), and it's used to decided whether this operation will cause out-of-bound acce

[clang] [analyzer] Avoid unnecessary super region invalidation in `CStringChecker` (PR #146212)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (flovent) Changes Bounded string functions takes smallest of two values as it's copy size (`amountCopied` variable in `evalStrcpyCommon`), and it's used to decided whether this operation will cause out-of-bound access and invalidate

[clang] [analyzer] Avoid unnecessary super region invalidation in `CStringChecker` (PR #146212)

2025-06-28 Thread via cfe-commits
https://github.com/flovent created https://github.com/llvm/llvm-project/pull/146212 Bounded string functions takes smallest of two values as it's copy size (`amountCopied` variable in `evalStrcpyCommon`), and it's used to decided whether this operation will cause out-of-bound access and invali

[clang] [docs][coroutines] Revamp "Debugging C++ coroutines" (PR #142651)

2025-06-28 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clangd-ubuntu-tsan` running on `clangd-ubuntu-clang` while building `clang` at step 5 "build-clangd-clangd-index-server-clangd-indexer". Full details are available at: https://lab.llvm.org/buildbot/#/builders/134/builds/21502

[clang] [docs][coroutines] Revamp "Debugging C++ coroutines" (PR #142651)

2025-06-28 Thread Adrian Vogelsgesang via cfe-commits
@@ -8,470 +8,966 @@ Debugging C++ Coroutines Introduction -For performance and other architectural reasons, the C++ Coroutines feature in -the Clang compiler is implemented in two parts of the compiler. Semantic -analysis is performed in Clang, and Coroutine cons

[clang] [docs][coroutines] Revamp "Debugging C++ coroutines" (PR #142651)

2025-06-28 Thread Adrian Vogelsgesang via cfe-commits
https://github.com/vogelsgesang closed https://github.com/llvm/llvm-project/pull/142651 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] b8f1228 - [docs][coroutines] Revamp "Debugging C++ coroutines" (#142651)

2025-06-28 Thread via cfe-commits
Author: Adrian Vogelsgesang Date: 2025-06-28T15:27:55+02:00 New Revision: b8f122812e0ac4f262e98cf2661f4495553791e6 URL: https://github.com/llvm/llvm-project/commit/b8f122812e0ac4f262e98cf2661f4495553791e6 DIFF: https://github.com/llvm/llvm-project/commit/b8f122812e0ac4f262e98cf2661f4495553791e6

[clang] [clang][analyzer] Fix the false positive ArgInitializedness warning on unnamed bit-field (PR #145066)

2025-06-28 Thread via cfe-commits
https://github.com/Tedlion updated https://github.com/llvm/llvm-project/pull/145066 >From 03004d9a9348e365a2d2d05e69f83fc404ddb605 Mon Sep 17 00:00:00 2001 From: tangwy Date: Sat, 21 Jun 2025 00:22:10 +0800 Subject: [PATCH 1/6] [clang][analyzer] Fix the false positive ArgInitializedness warnin

[clang] [CIR] Upstream GenericSelectionExpr (PR #146211)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangir @llvm/pr-subscribers-clang Author: Amr Hesham (AmrDeveloper) Changes Upstream GenericSelectionExpr for ScalarExpr --- Full diff: https://github.com/llvm/llvm-project/pull/146211.diff 2 Files Affected: - (modified) clang/lib/CIR/CodeGen/CIRGen

[clang] [CIR] Upstream GenericSelectionExpr (PR #146211)

2025-06-28 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/146211 Upstream GenericSelectionExpr for ScalarExpr >From 351422fe7f124351b06048048dfa28dd03ca35e5 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 28 Jun 2025 15:10:36 +0200 Subject: [PATCH] [CIR] Upstream

[clang] [llvm] [NFC][analyzer] Remove Z3-as-constraint-manager hacks from lit test code (PR #145731)

2025-06-28 Thread Michał Górny via cfe-commits
mgorny wrote: Unfortunately, after fixing the immediate issue I'm hitting another issue: `%host_cxx` is compiling a 64-bit library when doing `-m32` build for x86 — meaning the test run now fails due to ABI mismatch: ``` FAIL: Clang :: Analysis/z3-crosscheck-max-attempts.cpp (1537 of 21645) **

[clang] [llvm] [NFC][analyzer] Remove Z3-as-constraint-manager hacks from lit test code (PR #145731)

2025-06-28 Thread Michał Górny via cfe-commits
mgorny wrote: It's rather caused by doing a multilib build — in general you can't really use `CMAKE_CXX_COMPILER` outside CMake, since CMake is doing some toolchain magic on that, and you can't reproduce it right in lit. Unfortunately, I can't think of a good way of determining whether to run

[clang] [llvm] [NFC][analyzer] Remove Z3-as-constraint-manager hacks from lit test code (PR #145731)

2025-06-28 Thread Balazs Benics via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: steakhal wrote: I dont think we should (or you) invest too much. We can just mark this special case with UNSUPPORTED and move on. Is this issue caused by the standalone

[clang] [llvm] [NFC][analyzer] Remove Z3-as-constraint-manager hacks from lit test code (PR #145731)

2025-06-28 Thread Michał Górny via cfe-commits
mgorny wrote: I'm going to try moving the shared object build into CMake. https://github.com/llvm/llvm-project/pull/145731 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][analyzer] Fix the false positive ArgInitializedness warning on unnamed bit-field (PR #145066)

2025-06-28 Thread via cfe-commits
@@ -2122,8 +2122,21 @@ SVal RegionStoreManager::getBindingForField(RegionBindingsConstRef B, if (const std::optional &V = B.getDirectBinding(R)) return *V; - // If the containing record was initialized, try to get its constant value. + // UnnamedBitField is always Und

[clang] [CIR] Implement NotEqualOp for ComplexType (PR #146129)

2025-06-28 Thread Amr Hesham via cfe-commits
@@ -901,13 +901,9 @@ class ScalarExprEmitter : public StmtVisitor { assert(e->getOpcode() == BO_EQ || e->getOpcode() == BO_NE); BinOpInfo boInfo = emitBinOps(e); - if (e->getOpcode() == BO_EQ) { -result = -builder.create(loc, boInfo.lhs, b

[clang] [CIR] Implement NotEqualOp for ComplexType (PR #146129)

2025-06-28 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/146129 >From 964a930b9f96423d04155b9972bfd8540c59d911 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 27 Jun 2025 20:10:48 +0200 Subject: [PATCH 1/4] [CIR] Implement NotEqualOp for ComplexType --- clang/i

[clang] [CIR] Implement NotEqualOp for ComplexType (PR #146129)

2025-06-28 Thread Henrich Lauko via cfe-commits
@@ -901,13 +901,9 @@ class ScalarExprEmitter : public StmtVisitor { assert(e->getOpcode() == BO_EQ || e->getOpcode() == BO_NE); BinOpInfo boInfo = emitBinOps(e); - if (e->getOpcode() == BO_EQ) { -result = -builder.create(loc, boInfo.lhs, b

[clang] [Clang][LoongArch] Match GCC behaviour when parsing FPRs in asm clobbers (PR #138391)

2025-06-28 Thread via cfe-commits
github-actions[bot] wrote: @ziyao233 Congratulations on having your first Pull Request (PR) merged into the LLVM Project! Your changes will be combined with recent changes from other authors, then tested by our [build bots](https://lab.llvm.org/buildbot/). If there is a problem with a build

[clang] [CIR] Comma Operator for ComplexType (PR #146204)

2025-06-28 Thread Henrich Lauko via cfe-commits
https://github.com/xlauko approved this pull request. lgtm https://github.com/llvm/llvm-project/pull/146204 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][LoongArch] Match GCC behaviour when parsing FPRs in asm clobbers (PR #138391)

2025-06-28 Thread via cfe-commits
https://github.com/heiher closed https://github.com/llvm/llvm-project/pull/138391 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 0ba456f - [Clang][LoongArch] Match GCC behaviour when parsing FPRs in asm clobbers (#138391)

2025-06-28 Thread via cfe-commits
Author: Yao Zi Date: 2025-06-28T16:47:05+08:00 New Revision: 0ba456fcc6b1c8504f1596f6f5cb2c188a869ac7 URL: https://github.com/llvm/llvm-project/commit/0ba456fcc6b1c8504f1596f6f5cb2c188a869ac7 DIFF: https://github.com/llvm/llvm-project/commit/0ba456fcc6b1c8504f1596f6f5cb2c188a869ac7.diff LOG: [

[clang] [Clang][LoongArch] Match GCC behaviour when parsing FPRs in asm clobbers (PR #138391)

2025-06-28 Thread via cfe-commits
https://github.com/heiher approved this pull request. LGTM. https://github.com/llvm/llvm-project/pull/138391 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Comma Operator for ComplexType (PR #146204)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Amr Hesham (AmrDeveloper) Changes This change adds support for the comma operator for ComplexType https://github.com/llvm/llvm-project/issues/141365 --- Full diff: https://github.com/llvm/llvm-project/pull/146204.diff 2 Files Affected:

[clang] [CIR] Comma Operator for ComplexType (PR #146204)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangir Author: Amr Hesham (AmrDeveloper) Changes This change adds support for the comma operator for ComplexType https://github.com/llvm/llvm-project/issues/141365 --- Full diff: https://github.com/llvm/llvm-project/pull/146204.diff 2 Files Affected

[clang] [CIR] Comma Operator for ComplexType (PR #146204)

2025-06-28 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/146204 This change adds support for the comma operator for ComplexType https://github.com/llvm/llvm-project/issues/141365 >From 27ea475851bcee84c6364e2abb9e5b4d3bf9a03c Mon Sep 17 00:00:00 2001 From: AmrDeveloper

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread Marco Vitale via cfe-commits
https://github.com/mrcvtl updated https://github.com/llvm/llvm-project/pull/145164 >From 37c57131c397d4aeaef7fe5b860d1983f1e4bdc2 Mon Sep 17 00:00:00 2001 From: Marco Vitale Date: Sat, 21 Jun 2025 14:01:53 +0200 Subject: [PATCH] [Sema] Fix lifetime extension for temporaries in range-based for

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread Marco Vitale via cfe-commits
https://github.com/mrcvtl deleted https://github.com/llvm/llvm-project/pull/145164 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread Marco Vitale via cfe-commits
https://github.com/mrcvtl deleted https://github.com/llvm/llvm-project/pull/145164 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread Marco Vitale via cfe-commits
@@ -1585,6 +1590,20 @@ class VarDecl : public DeclaratorDecl, public Redeclarable { NonParmVarDeclBits.IsCXXCondDecl = true; } + /// Determine whether this variable is the compiler-generated '__range' + /// variable used to hold the range expression in a C++11 and lat

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread Marco Vitale via cfe-commits
@@ -2740,6 +2741,7 @@ void ASTWriter::WriteDeclAbbrevs() { // isInline, isInlineSpecified, isConstexpr, // isInitCapture, isPrevDeclInSameScope, hasInitWithSideEffects, // EscapingByref, HasDeducedType, ImplicitParamKind, isObjCForDecl +

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread Marco Vitale via cfe-commits
mrcvtl wrote: > > but why can’t we use InLifetimeExtendingContext flag here? > > Is there a subtle difference I’m missing? > > This flag will tiger subroutines to collect `MaterializedTemporaryExpr` and > rebuild default init/arg。 All we need to know here is that `ExtendingDecl` is > a C++ `__

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-28 Thread Marco Vitale via cfe-commits
https://github.com/mrcvtl updated https://github.com/llvm/llvm-project/pull/145164 >From b5146278ce5059b6bf0312f18f509022de5fd661 Mon Sep 17 00:00:00 2001 From: Marco Vitale Date: Sat, 21 Jun 2025 14:01:53 +0200 Subject: [PATCH 1/2] [Sema] Fix lifetime extension for temporaries in range-based

[clang] [clang][analyzer] Fix the false positive ArgInitializedness warning on unnamed bit-field (PR #145066)

2025-06-28 Thread via cfe-commits
https://github.com/Tedlion updated https://github.com/llvm/llvm-project/pull/145066 >From 03004d9a9348e365a2d2d05e69f83fc404ddb605 Mon Sep 17 00:00:00 2001 From: tangwy Date: Sat, 21 Jun 2025 00:22:10 +0800 Subject: [PATCH 1/5] [clang][analyzer] Fix the false positive ArgInitializedness warnin

[clang] [CIR] Implement NotEqualOp for ComplexType (PR #146129)

2025-06-28 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/146129 >From 964a930b9f96423d04155b9972bfd8540c59d911 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 27 Jun 2025 20:10:48 +0200 Subject: [PATCH 1/3] [CIR] Implement NotEqualOp for ComplexType --- clang/i

[clang] [clang-format] Fix an off-by-1 bug with -length option (PR #143302)

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

[clang] [clang-format] Fix a bug in `ReflowComments: Always` (PR #146202)

2025-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fixes #39150 --- Full diff: https://github.com/llvm/llvm-project/pull/146202.diff 2 Files Affected: - (modified) clang/lib/Format/BreakableToken.cpp (+1-2) - (modified) clang/unittests/Format/FormatTest

[clang] [clang-format] Fix a bug in `ReflowComments: Always` (PR #146202)

2025-06-28 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/146202 Fixes #39150 >From 00c0c25a5f17a0077cfc8660020391684aa5 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Sat, 28 Jun 2025 00:25:02 -0700 Subject: [PATCH] [clang-format] Fix a bug in `ReflowComments: Always` Fi

[clang] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2025-06-28 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-remote-linux-ubuntu` running on `as-builder-9` while building `clang` at step 16 "test-check-lldb-api". Full details are available at: https://lab.llvm.org/buildbot/#/builders/195/builds/11073 Here is the relevant piec

[clang] [Clang][LoongArch] Match GCC behaviour when parsing FPRs in asm clobbers (PR #138391)

2025-06-28 Thread Yao Zi via cfe-commits
@@ -5,6 +5,7 @@ // CHECK-LABEL: @test_r0 // CHECK: call void asm sideeffect "", "{$r0}"(i32 undef) +// CHECK: call void asm sideeffect "", "{$r0}"(i32 undef) ziyao233 wrote: Thanks for the hint, I've adapted the scheme :) https://github.com/llvm/llvm-project

[clang] e34e021 - [clang] Fix tests requiring Z3 headers in standalone builds (#146200)

2025-06-28 Thread via cfe-commits
Author: Michał Górny Date: 2025-06-28T09:10:49+02:00 New Revision: e34e02128ec5eb89e36a8f0f7307dcbcfecabbee URL: https://github.com/llvm/llvm-project/commit/e34e02128ec5eb89e36a8f0f7307dcbcfecabbee DIFF: https://github.com/llvm/llvm-project/commit/e34e02128ec5eb89e36a8f0f7307dcbcfecabbee.diff

[clang] [clang] Fix tests requiring Z3 headers in standalone builds (PR #146200)

2025-06-28 Thread Michał Górny via cfe-commits
https://github.com/mgorny closed https://github.com/llvm/llvm-project/pull/146200 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix tests requiring Z3 headers in standalone builds (PR #146200)

2025-06-28 Thread Michał Górny via cfe-commits
mgorny wrote: Thanks for the prompt review! https://github.com/llvm/llvm-project/pull/146200 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2025-06-28 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-aarch64-ubuntu` running on `linaro-lldb-aarch64-ubuntu` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/59/builds/20116 Here is the relevant piece of the