[clang] [ASTReader] Remove assert in GetExternalDeclStmt (PR #143739)

2025-06-11 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: I think we shouldn't remove the assertion. Your test passes with the removal of the assertion since the initializers are not complex. So it ends quickly. But if it is a complex initialization which triggers more deserialization, I feel it will be problematic. I think the poi

[clang] bb3b830 - [NFC] [C++20] [Modules] Add a test module local declaration lookup

2025-06-11 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2025-06-12T10:48:34+08:00 New Revision: bb3b8306dc226c4dc4dfde36444b43476eea66ee URL: https://github.com/llvm/llvm-project/commit/bb3b8306dc226c4dc4dfde36444b43476eea66ee DIFF: https://github.com/llvm/llvm-project/commit/bb3b8306dc226c4dc4dfde36444b43476eea66ee.diff LO

[clang] f09050f - [C++20] [Modules] Fix module local lookup ambiguousity

2025-06-11 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2025-06-12T11:48:09+08:00 New Revision: f09050fdc85074869f0b34f0d9e061a74ef549ee URL: https://github.com/llvm/llvm-project/commit/f09050fdc85074869f0b34f0d9e061a74ef549ee DIFF: https://github.com/llvm/llvm-project/commit/f09050fdc85074869f0b34f0d9e061a74ef549ee.diff LO

[clang] [llvm] [CoroSplit] Rise lifetime.end to get smaller frame size (PR #143333)

2025-06-09 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 commented: If we can move lifetimes, this should be a general optimization. We don't have to (and shouldn't) put this in Coroutine passes. Let's make it a general pass and send it for review for wider visibility. https://github.com/llvm/llvm-project/pull/14 __

[clang] [C++20][Modules] Fix false compilation error with constexpr (PR #143168)

2025-06-08 Thread Chuanqi Xu via cfe-commits
@@ -6781,7 +6781,7 @@ static bool HandleConstructorCall(const Expr *E, const LValue &This, // and make sure we've initialized every step along it. auto IndirectFieldChain = IFD->chain(); for (auto *C : IndirectFieldChain) { -FD = cast(C); +FD

[clang] [C++20][Modules] Fix false compilation error with constexpr (PR #143168)

2025-06-08 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/143168 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CoroSplit] Rise lifetime.end to get smaller frame size (PR #143333)

2025-06-09 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: lifetimes are widely used. I don't have a clear idea for position yet. https://github.com/llvm/llvm-project/pull/14 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [ASTReader] Remove assert in GetExternalDeclStmt (PR #143739)

2025-06-12 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: > > I think we shouldn't remove the assertion. Your test passes with the > > removal of the assertion since the initializers are not complex. So it ends > > quickly. But if it is a complex initialization which triggers more > > deserialization, I feel it will be problematic.

[clang] 1d1f9af - [C++20] [Modules] Treat directly imported internal partition unit as reachable

2025-06-12 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2025-06-12T17:46:33+08:00 New Revision: 1d1f9afe911c360b9505b5fd2c712cb112c8aa5f URL: https://github.com/llvm/llvm-project/commit/1d1f9afe911c360b9505b5fd2c712cb112c8aa5f DIFF: https://github.com/llvm/llvm-project/commit/1d1f9afe911c360b9505b5fd2c712cb112c8aa5f.diff LO

[clang] [Serialization] Fix source location data loss during decoding. (PR #145529)

2025-06-25 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: > If the module file index is 0, we use delta encoding (see [this code > path](https://github.com/llvm/llvm-project/blob/01b288fe6a1e627954329198ed5641f2bf55ee8d/clang/include/clang/Serialization/SourceLocationEncoding.h#L165-L168)). > However, the 1) case can produce a 33-bit

[clang] Reland "[Modules] Record whether VarDecl initializers contain side effects" (PR #145447)

2025-06-25 Thread Chuanqi Xu via cfe-commits
@@ -16719,6 +16719,9 @@ static bool EvaluateInPlace(APValue &Result, EvalInfo &Info, const LValue &This, const Expr *E, bool AllowNonLiteralTypes) { assert(!E->isValueDependent()); + if (E->getType().isNull()) ChuanqiXu9 wrote:

[clang] [clang-tools-extra] [clang][modules] Serialize `CodeGenOptions` (PR #146422)

2025-07-02 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: > I'm not suggesting to treat CodeGenOptions as incompatible by default. For > now I'm just trying to remove the duplication and improve the > infrastructure.CodeGenOptions are still benign by default, and can only be > marked as compatible, which doesn't have any impact on e

[clang] [NFC] [C++] [Modules] Mark P1979 as implemented and add test (PR #146841)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/146841 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] [C++] [Modules] Mark P1979 as implemented and add test (PR #146841)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/146841 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 5f62c79 - [C++20] [Modules] Use current named module to do module local lookup

2025-07-03 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2025-07-03T19:03:52+08:00 New Revision: 5f62c791061d5fb39e3686126042e4a090132efc URL: https://github.com/llvm/llvm-project/commit/5f62c791061d5fb39e3686126042e4a090132efc DIFF: https://github.com/llvm/llvm-project/commit/5f62c791061d5fb39e3686126042e4a090132efc.diff LO

[clang] [Serialization] Fix lazy template loading (PR #133057)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. BTW, I've landed the 3 patches (excluding the problematic reported by Google) internally and we've used it for months. It looks good. https://github.com/llvm/llvm-project/pull/133057 ___ cfe-co

[clang] [clang][modules-driver] Add scanner to detect C++20 module presence (PR #145220)

2025-07-03 Thread Chuanqi Xu via cfe-commits
@@ -790,6 +792,35 @@ class Driver { /// compilation based on which -f(no-)?lto(=.*)? option occurs last. void setLTOMode(const llvm::opt::ArgList &Args); + /// BuildDefaultActions - Constructs the list of actions to perform + /// for the provided arguments, which are onl

[clang] [clang][modules-driver] Add scanner to detect C++20 module presence (PR #145220)

2025-07-03 Thread Chuanqi Xu via cfe-commits
@@ -577,6 +577,16 @@ def err_drv_reduced_module_output_overrided : Warning< "please consider use '-fmodule-output=' to specify the output file for reduced BMI explicitly">, InGroup>; +def remark_found_cxx20_module_usage : Remark< + "found C++20 module usage in file '%0'"

[clang] [clang][modules-driver] Add scanner to detect C++20 module presence (PR #145220)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 edited https://github.com/llvm/llvm-project/pull/145220 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][modules-driver] Add scanner to detect C++20 module presence (PR #145220)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 requested changes to this pull request. I still hope we can get a new name. It is important for me to understand if some code may affect C++20 module or not by its name. I feel this can be helpful for other developers too. https://github.com/llvm/llvm-project/pull

[clang] [clang-cl] Accept `cl`-style output arguments (`/Fo`, `-Fo`) for `--precompile` (PR #121046)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 edited https://github.com/llvm/llvm-project/pull/121046 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-cl] Accept `cl`-style output arguments (`/Fo`, `-Fo`) for `--precompile` (PR #121046)

2025-07-03 Thread Chuanqi Xu via cfe-commits
@@ -14,3 +14,11 @@ //--- test.pcm // CPP20WARNING-NOT: clang-cl: warning: argument unused during compilation: '/std:c++20' [-Wunused-command-line-argument] + +// test whether the following outputs %Hello.bmi ChuanqiXu9 wrote: ```suggestion // test whether th

[clang] [clang-cl] Accept `cl`-style output arguments (`/Fo`, `-Fo`) for `--precompile` (PR #121046)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. Given the problem is important (I've heard the problem for clang-cl with modules several times) and the author have been active on this direction for years, I think I can trust him even if I can't test it actually. So LGTM. I'll land th

[clang] [clang] Refactor `LangOptions` to specify AST effect as X macro arg (PR #146766)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/146766 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Refactor `CodeGenOptions` to specify AST effect as X macro arg (PR #146910)

2025-07-03 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/146910 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-cl] Accept `cl`-style output arguments (`/Fo`, `-Fo`) for `--precompile` (PR #121046)

2025-07-04 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: CC @mathstuf @bradking https://github.com/llvm/llvm-project/pull/121046 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Serialization] Remove an unnecessarycast (NFC) (PR #147204)

2025-07-06 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/147204 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][modules-driver] Add scanner to detect C++20 module presence (PR #145220)

2025-07-06 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/145220 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] [C++] [Modules] Mark P2615 as implemented and add test (PR #147135)

2025-07-06 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. LGTM. Thanks. A small suggestion is, it is better to paste the link of the paper. So that I don't have to find it my self. https://github.com/llvm/llvm-project/pull/147135 ___ cfe-commits mail

[clang] [NFC] [C++] [Modules] Mark P1811 as implemented and add test (PR #146993)

2025-07-06 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/146993 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] [C++] [Modules] Mark P2788 as implemented and add test (PR #147138)

2025-07-06 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/147138 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 5186d4a - [NFC] [clang] Fix a test regression

2025-06-30 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2025-06-30T18:56:29+08:00 New Revision: 5186d4aeeeca56a77404c2842e494524b7cdd4ba URL: https://github.com/llvm/llvm-project/commit/5186d4aeeeca56a77404c2842e494524b7cdd4ba DIFF: https://github.com/llvm/llvm-project/commit/5186d4aeeeca56a77404c2842e494524b7cdd4ba.diff LO

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: FWIW, I fixed it in https://github.com/llvm/llvm-project/commit/5186d4aeeeca56a77404c2842e494524b7cdd4ba to avoid affecting more people longer. https://github.com/llvm/llvm-project/pull/146247 ___ cfe-commits mailing list cfe-commit

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/146247 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: Please use a new email name. We don't accept github.noreply mail. https://github.com/llvm/llvm-project/pull/146247 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-29 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: I prefer a warning instead of hard error. There are already users who uses this. https://github.com/llvm/llvm-project/pull/146247 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/

[clang] [clang][modules-driver] Add scanner to detect C++20 module presence (PR #145220)

2025-07-01 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 commented: I prefer to change the term "explicit module" in the code to something like `CXX20 module` or `named module` or whatever. Since when I read the term `explicit module` I assumed it is a style to build clang header modules. https://github.com/llvm/llvm-p

[clang] [clang-tools-extra] [clang][modules] Serialize `CodeGenOptions` (PR #146422)

2025-07-01 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: > > How does this patch handle consistency issue? e.g., What if `a.pcm` is > > compiled with `-O0` but the consumer is compiled with `-O1`? I hope we > > won't break such things. > > All `Optimize`, `OptimizeSize` and `NoInlineDefine` were `COMPATIBLE_LANGOPT` > in `LangOpti

[clang] 8a5b97a - Revert "[clang] [modules] Add err_main_in_named_module (#146247)"

2025-06-30 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2025-06-30T23:22:31+08:00 New Revision: 8a5b97a7205db189ca82f44dec7a399c2b5da546 URL: https://github.com/llvm/llvm-project/commit/8a5b97a7205db189ca82f44dec7a399c2b5da546 DIFF: https://github.com/llvm/llvm-project/commit/8a5b97a7205db189ca82f44dec7a399c2b5da546.diff LO

[clang] [clang] Fix broken autocomplete test (PR #146326)

2025-06-30 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: I landed it in https://github.com/llvm/llvm-project/commit/5186d4aeeeca56a77404c2842e494524b7cdd4ba https://github.com/llvm/llvm-project/pull/146326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[clang] [clang] Fix broken autocomplete test (PR #146326)

2025-06-30 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/146326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: Didn't know it. I'll revert this. @ashwinbanwari it looks like you need to remove the diagnostics with `extern "C++" main` and apply it with libc++ and land this finally. https://github.com/llvm/llvm-project/pull/146247 ___ cfe-com

[clang] [clang-tools-extra] [clang][modules] Serialize `CodeGenOptions` (PR #146422)

2025-06-30 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 commented: This has a stronger impact on C++20 modules since C++20 modules need to generate codes. How does this patch handle consistency issue? e.g., What if `a.pcm` is compiled with `-O0` but the consumer is compiled with `-O1`? I hope we won't break such thin

[clang] [clang][modules-driver] Add scanner to detect C++20 module presence (PR #145220)

2025-06-30 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: > This PR is part of a series aimed at implementing native support for explicit > module builds from the Clang driver. This is confusing. Since explicit modules is an unrelated term with C++20 modules. https://github.com/llvm/llvm-project/pull/145220

[clang] [libcxx] [clang] [modules] Implement P3618R0: Allow attaching main to the global module (PR #146461)

2025-06-30 Thread Chuanqi Xu via cfe-commits
@@ -12400,12 +12400,9 @@ bool Sema::CheckFunctionDeclaration(Scope *S, FunctionDecl *NewFD, void Sema::CheckMain(FunctionDecl *FD, const DeclSpec &DS) { // [basic.start.main]p3 - //The main function shall not be declared with a linkage-specification. - if (FD->isExter

[clang] WIP: fix assert in hasInitWithSideEffects (PR #146468)

2025-06-30 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 commented: The change LGTM but I want a test to avoid further regression. https://github.com/llvm/llvm-project/pull/146468 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/list

[clang] [libcxx] [clang] [modules] Implement P3618R0: Allow attaching main to the global module (PR #146461)

2025-06-30 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. Sounds good. I'll merge this after the CI gets green. https://github.com/llvm/llvm-project/pull/146461 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[clang] [clang] [modules] Add err_main_in_named_module (PR #146635)

2025-07-02 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/146635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146635)

2025-07-02 Thread Chuanqi Xu via cfe-commits
@@ -12486,6 +12486,14 @@ void Sema::CheckMain(FunctionDecl *FD, const DeclSpec &DS) { : FixItHint()); FD->setInvalidDecl(true); } + +// In C++ [basic.start.main]p3, it is said a program attaching main to a +// named module is i

[clang] [clang] [modules] Add err_main_in_named_module (PR #146635)

2025-07-02 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 edited https://github.com/llvm/llvm-project/pull/146635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146635)

2025-07-02 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: Please make sure the libc++ tests won't get affected. I am not sure if the modules related tests in libc++ run by default. https://github.com/llvm/llvm-project/pull/146635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http

[clang] [libcxx] [clang] [modules] Implement P3618R0: Allow attaching main to the global module (PR #146461)

2025-07-01 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/146461 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
@@ -650,6 +650,9 @@ Improvements to Clang's diagnostics #GH69470, #GH59391, #GH58172, #GH46215, #GH45915, #GH45891, #GH44490, #GH36703, #GH32903, #GH23312, #GH69874. +- A warning is now emitted when ``main`` is attached to a named module, + which can be turned off with ``

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/146247 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. LGTM. Thanks. https://github.com/llvm/llvm-project/pull/146247 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
@@ -1062,6 +1062,8 @@ def err_constexpr_main : Error< "'main' is not allowed to be declared %select{constexpr|consteval}0">; def err_deleted_main : Error<"'main' is not allowed to be deleted">; def err_mainlike_template_decl : Error<"%0 cannot be a template">; +def warn_main_

[clang] [clang] [modules] Add err_main_in_named_module (PR #146247)

2025-06-30 Thread Chuanqi Xu via cfe-commits
@@ -1062,6 +1062,8 @@ def err_constexpr_main : Error< "'main' is not allowed to be declared %select{constexpr|consteval}0">; def err_deleted_main : Error<"'main' is not allowed to be deleted">; def err_mainlike_template_decl : Error<"%0 cannot be a template">; +def warn_main_

[clang] [clang] odr-checker fix for conversion operators (PR #146153)

2025-06-29 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. SGTM https://github.com/llvm/llvm-project/pull/146153 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] Extend SourceLocation to 64 bits. (PR #147292)

2025-07-07 Thread Chuanqi Xu via cfe-commits
@@ -43,17 +46,24 @@ namespace clang { // Macro locations have the top bit set, we rotate by one so it is the low bit. class SourceLocationEncoding { using UIntTy = SourceLocation::UIntTy; - constexpr static unsigned UIntBits = CHAR_BIT * sizeof(UIntTy); static UIntTy en

[clang] [NFC] [C++] [Modules] Mark P2788 as implemented and add test (PR #147138)

2025-07-07 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/147138 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] [C++] [Modules] Mark P1811 as implemented and add test (PR #146993)

2025-07-07 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/146993 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] Extend SourceLocation to 64 bits. (PR #147292)

2025-07-07 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 edited https://github.com/llvm/llvm-project/pull/147292 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] [C++] [Modules] Mark P2615 as implemented and add test (PR #147135)

2025-07-07 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/147135 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] [C++] [Modules] Mark P2115 as implemented and add test (PR #147489)

2025-07-08 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/147489 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] [C++] [Modules] Mark P2115 as implemented and add test (PR #147489)

2025-07-08 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/147489 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] Extend SourceLocation to 64 bits. (PR #147292)

2025-07-07 Thread Chuanqi Xu via cfe-commits
@@ -43,17 +46,24 @@ namespace clang { // Macro locations have the top bit set, we rotate by one so it is the low bit. class SourceLocationEncoding { using UIntTy = SourceLocation::UIntTy; - constexpr static unsigned UIntBits = CHAR_BIT * sizeof(UIntTy); static UIntTy en

[clang] [clang-tools-extra] [clang] Extend SourceLocation to 64 bits. (PR #147292)

2025-07-07 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 commented: Have you tested this with google's internal modules test? If yes, then LG. https://github.com/llvm/llvm-project/pull/147292 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang] Added partial support for compiling C++20 modules and header-units without scanning. (PR #147682)

2025-07-09 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: The size of the patch is too big to review. And personally I don't have such a time to review it recently. Also from the community's perspective, the maintainablity of large patches is questionable. I think, you can achieve it with another direction. Instead of adding these

[clang] [NFC][C++][Modules] Refine basic.link.p3 and add test for P2788R0 (PR #147945)

2025-07-10 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/147945 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][C++][Modules] Refine basic.link.p3 and add test for P2788R0 (PR #147945)

2025-07-10 Thread Chuanqi Xu via cfe-commits
@@ -51,4 +39,71 @@ template module module_var_template; // This is a variable named 'import' that shadows the type 'import' above. struct X {} import; -#endif + +//--- ImportError1.cppm +module; + +struct import { struct inner {}; }; +struct module { struct inner {}; }; + +con

[clang] [NFC][C++][Modules] Refine basic.link.p3 and add test for P2788R0 (PR #147945)

2025-07-10 Thread Chuanqi Xu via cfe-commits
@@ -51,4 +39,71 @@ template module module_var_template; // This is a variable named 'import' that shadows the type 'import' above. struct X {} import; -#endif + +//--- ImportError1.cppm +module; + +struct import { struct inner {}; }; +struct module { struct inner {}; }; + +con

[clang] [NFC][C++][Modules] Refine basic.link.p3 and add test for P2788R0 (PR #147945)

2025-07-10 Thread Chuanqi Xu via cfe-commits
@@ -51,4 +39,71 @@ template module module_var_template; // This is a variable named 'import' that shadows the type 'import' above. struct X {} import; -#endif + +//--- ImportError1.cppm +module; + +struct import { struct inner {}; }; +struct module { struct inner {}; }; + +con

[clang] [NFC][C++][Modules] Refine basic.link.p3 and add test for P2788R0 (PR #147945)

2025-07-10 Thread Chuanqi Xu via cfe-commits
@@ -51,4 +39,71 @@ template module module_var_template; // This is a variable named 'import' that shadows the type 'import' above. struct X {} import; -#endif + +//--- ImportError1.cppm +module; + +struct import { struct inner {}; }; +struct module { struct inner {}; }; + +con

[clang] [NFC][C++][Modules] Refine basic.link.p3 and add test for P2788R0 (PR #147945)

2025-07-10 Thread Chuanqi Xu via cfe-commits
@@ -51,4 +39,71 @@ template module module_var_template; // This is a variable named 'import' that shadows the type 'import' above. struct X {} import; -#endif + +//--- ImportError1.cppm +module; + +struct import { struct inner {}; }; +struct module { struct inner {}; }; + +con

[clang-tools-extra] aa99026 - [NFC] [clangd] [Modules] Logging more if compilation failed

2025-07-10 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2025-07-11T11:18:21+08:00 New Revision: aa9902691db5cbb9db77270902f615f3c0877deb URL: https://github.com/llvm/llvm-project/commit/aa9902691db5cbb9db77270902f615f3c0877deb DIFF: https://github.com/llvm/llvm-project/commit/aa9902691db5cbb9db77270902f615f3c0877deb.diff LO

<    19   20   21   22   23   24