[PATCH] D122314: [clang] Reformat

2022-03-24 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGde867c6d6ed8: [clang] Reformat (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://revi

[PATCH] D122394: [C++20][Modules] Correct an assert for modules-ts.

2022-03-24 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. Is this because of history that ModulesTS option != p1103 modules? I thought we wanted to make the former become the latter (i.e. ModuleTS is the same as CPlusPlusModules) This seems to be moving in the wrong direction. Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D122394: [C++20][Modules] Correct an assert for modules-ts.

2022-03-25 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. Understood. To document the approach: 1. clearly separate -fmodules-ts semantics (which are vague in places, but whatever) 2. implement c++20 modules semantics 3a) switch -fmodules-ts op

[PATCH] D122256: [clang][ABI] New C++20 module mangling scheme

2022-03-30 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGae4dce8659f3: [clang][ABI] New C++20 module mangling scheme (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Changed prior to commit: https://reviews.llvm.o

[PATCH] D122885: [clang] Draft: Implement P1703R1

2022-04-01 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. I can;t really tell what you're doing. C++20 lexes import (&module) declarations as preprocessor directives. the parser must also recognize only such declarations that came through from lexing such directives. It is unrelated to #import. GCC's implementation drops

[PATCH] D122885: [clang] Draft: Implement P1703R1

2022-04-01 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. oh, also in 'import "bob";', "bob" needs to be lexed as a #include name, not a string. (and likewise 'import ;') Hence treating these lines in the preprocessor in directive-processing-mode was the way GCC went. Comment at: clang/test/Modules/P1703R

[PATCH] D122885: [clang] Draft: Implement P1703R1

2022-04-04 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. Ah, I'd had a thinko about what 1703 was. that's superseded by p1757. That's what is needed. (your patch makes more sense in the 1703 context) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122885/new/ https://reviews.l

[PATCH] D123120: [clang] Document p1703 not needed

2022-04-05 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG54c50336e4c1: [clang] Document p1703 not needed (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Chang

[PATCH] D123119: [clang][NFC] Add specificity to compatibility hack

2022-04-06 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGba4482f48199: [clang][NFC] Add specificity to compatibility hack (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cf

[PATCH] D122885: [clang] Draft: Implement P1703R1

2022-04-06 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan requested changes to this revision. urnathan added a comment. This revision now requires changes to proceed. Either update this when you're ready, or abandon and create a new one for 1857. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D12288

[PATCH] D123141: [clang][DOC] Document module mangler changes

2022-04-06 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG482fad4a3fcb: [clang][DOC] Document module mangler changes (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SIN

[PATCH] D121590: [C++20][Modules][Driver][HU 3/N] Handle foo.h with -fmodule-header and/or C++ invocation.

2022-03-22 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. looks resonable, 1 nit. Comment at: clang/lib/Driver/Driver.cpp:2453 // Disambiguate headers that are meant to be header units from those -// intended to

[PATCH] D121098: [C++20][Modules][HU 4/5] Handle pre-processed header units.

2022-03-22 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. yeah, gcc's preprocessor has peeking code to deal with this (more generally than modules) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121098/new/ https://reviews.llvm.org/D121098 ___

[PATCH] D122119: [C++20][Modules] Adjust handling of exports of namespaces and using-decls.

2022-03-22 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. In D122119#3398823 , @iains wrote: > > With the change here we now get: > cannot export redeclaration 'f' here since the previous declaration has > internal linkage > cannot export redeclaration 'S' here since the previous d

[PATCH] D122119: [C++20][Modules] Adjust handling of exports of namespaces and using-decls.

2022-03-22 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. In D122119#3398949 , @ChuanqiXu wrote: > > The first feeling I saw the change is that not every C++ programmer knows > about linkage. OK, it depends on the environment really and every one might > has their own opinion. Yo

[PATCH] D122119: [C++20][Modules] Adjust handling of exports of namespaces and using-decls.

2022-03-23 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. In D122119#3401322 , @ChuanqiXu wrote: > > I think the example is invalid since it violates [[ > http://eel.is/c++draft/module.interface#6 | [module.interface]p6 ]] > explicitly. If this is intended behavior or by design, w

[PATCH] D121099: [C++20][Modules][HU 5/5] Add fdirectives-only mode for preprocessing output.

2022-03-23 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. Kind of surprised this wasn't already a thing :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121099/new/ https://reviews.llvm.org/D121099

[PATCH] D123220: [clang] Verify internal entity module mangling

2022-04-07 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG9eda5fc0c6ea: [clang] Verify internal entity module mangling (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Changed prior to commit: https://reviews.llvm.

[PATCH] D118437: [NFC] [Modules] Refactor ODR checking for default template argument in ASTReader

2022-02-07 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. Looks like a good cleanup. Let me know what you think about the idea of retaining the switch. Comment at: clang/lib/Serialization/ASTReader.cpp:10176-10184 +if (auto *TTP = dyn_cast(D)) + return TTP->hasDefaultArgument() && +

[PATCH] D118804: Revert "[Clang] Propagate guaranteed alignment for malloc and others"

2022-02-08 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. While C2X has blessed such smaller alignments, the x86_64 ABI (in particular), has not. However, using that ABI to justify 'It. Is. 16. Bytes.', is really an exercise in reality denial at this point. just thought I'd make it clear we have conflicting standards and pr

[PATCH] D115610: [C++20] [Modules] Don't create multiple global module fragment

2022-02-08 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. the landed version is good, with Richard's suggested member name change. Can't see a way of post-commit accepting? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D115610/new/ https://reviews.llvm.org/D115610 _

[PATCH] D118804: Revert "[Clang] Propagate guaranteed alignment for malloc and others"

2022-02-08 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. In D118804#3304280 , @aaron.ballman wrote: > In D118804#3304261 , @urnathan > wrote: > >> While C2X has blessed such smaller alignments, the x86_64 ABI (in >> particular), has not. Ho

[PATCH] D118437: [NFC] [Modules] Refactor ODR checking for default template argument in ASTReader

2022-02-09 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. ok, thanks for considering the suggestion. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118437/new/ https://reviews.llvm.org/D118437 _

[PATCH] D119333: [clang][NFC] Standard substitution checking cleanup

2022-02-10 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. urnathan marked an inline comment as done. Closed by commit rG815446cd3e16: [clang][NFC] Standard substitution checking cleanup (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits.

[PATCH] D119409: [C++20] [Modules] Remain variable's definition in module interface

2022-02-11 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/CodeGenCXX/static-variable-in-module.cpp:2-8 +// RUN: mkdir %t +// RUN: echo "struct S { S(); };" >> %t/foo.h +// RUN: echo "static S s = S();" >> %t/foo.h +// RUN: %clang -std=c++20 -I%t %s -S -emit-llvm -o - | FileCheck %s

[PATCH] D119409: [C++20] [Modules] Remain variable's definition in module interface

2022-02-11 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/CXX/modules-ts/basic/basic.def.odr/p4/module.cpp:5 // CHECK-DAG: @extern_var_exported = external {{(dso_local )?}}global -// CHECK-DAG: @inline_var_exported = linkonce_odr {{(dso_local )?}}global +// CHECK-DAG: @inline_var_e

[PATCH] D119409: [C++20] [Modules] Remain variable's definition in module interface

2022-02-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/CXX/modules-ts/basic/basic.def.odr/p4/module.cpp:5 // CHECK-DAG: @extern_var_exported = external {{(dso_local )?}}global -// CHECK-DAG: @inline_var_exported = linkonce_odr {{(dso_local )?}}global +// CHECK-DAG: @inline_var_e

[PATCH] D119409: [C++20] [Modules] Remain variable's definition in module interface

2022-02-15 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/CXX/modules-ts/basic/basic.def.odr/p4/module.cpp:5 // CHECK-DAG: @extern_var_exported = external {{(dso_local )?}}global -// CHECK-DAG: @inline_var_exported = linkonce_odr {{(dso_local )?}}global +// CHECK-DAG: @inline_var_e

[PATCH] D119748: [clang][NFC] Remove IgnoreLinkageSpecDecls

2022-02-15 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG02093906fa0f: [clang][NFC] Remove IgnoreLinkageSpecDecls (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D119823: [Modules] Add module structure output to -module-file-info.

2022-02-15 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Frontend/FrontendActions.cpp:817-824 +#if 0 + case Module::ModuleHeaderUnit: +return "Header Unit"; + case Module::ModulePartitionInterface: +return "Partition Interface"; + case Module::ModulePartitionImplementatio

[PATCH] D118893: [C++20][Modules] Track valid import state.

2022-02-15 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. Looks right to me -- I also implemented such a state machine in GCC's parser. There are a bunch of formatting issues to fix of course. Comment at: clang/include/clang/Basic/DiagnosticParseKinds.td:1543 +def err_import_not_allowed_here : Error< + "im

[PATCH] D114714: [C++20][Modules] Add enumerations for partition modules and stream them.

2022-02-15 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/include/clang/Basic/Module.h:109 -/// This is a C++ Modules TS module interface unit. +/// This is a C++ Modules TS or C++20 module interface unit. ModuleInterfaceUnit, I think it's confusing to con

[PATCH] D118893: [C++20][Modules] Track valid import state.

2022-02-15 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/include/clang/Basic/DiagnosticParseKinds.td:1543 +def err_import_not_allowed_here : Error< + "imports must be contiguous and immediately follow the module declaration">; +def err_import_in_global_fragment : Error< ---

[PATCH] D114714: [C++20][Modules] Add enumerations for partition modules and stream them.

2022-02-15 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/include/clang/Basic/Module.h:109 -/// This is a C++ Modules TS module interface unit. +/// This is a C++ Modules TS or C++20 module interface unit. ModuleInterfaceUnit, iains wrote: > urnathan wrote

[PATCH] D118893: [C++20][Modules][1/8] Track valid import state.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. thanks for indexing the subject lines! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118893/new/ https://reviews.llvm.org/D118893 _

[PATCH] D114714: [C++20][Modules][2/8] Add enumerations for partition modules and stream them.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. lgtm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114714/new/ https://reviews.llvm.org/D114714 ___

[PATCH] D119550: [clang] Itanium mangler constructors

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG082f328899be: [clang] Itanium mangler constructors (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D118586: [C++20][Modules][3/8] Initial handling for module partitions.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/include/clang/Sema/Sema.h:2989 /// \param ImportLoc The location of the 'import' keyword. - /// \param Path The module access path. + /// \param NamePath The module toplevel name as an access path. + /// \param Partition The

[PATCH] D118034: [C++20] [Modules] Don't complain about duplicated default template argument across modules

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Sema/SemaTemplate.cpp:2654-2656 +if (!C.hasSameType(DefaultArgumentX->getType(), + DefaultArgumentY->getType())) + return false; Can this ever trigger and the below expression te

[PATCH] D119823: [Modules] Add module structure output to -module-file-info.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/Modules/module-file-info-cxx20.cpp:26 + +#if TU == 1 + ChuanqiXu wrote: > iains wrote: > > ChuanqiXu wrote: > > > According to [[ > > > http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2020/p1857r3.html |

[PATCH] D119823: [Modules] Add module structure output to -module-file-info.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/Modules/module-file-info-cxx20.cpp:26 + +#if TU == 1 + urnathan wrote: > ChuanqiXu wrote: > > iains wrote: > > > ChuanqiXu wrote: > > > > According to [[ > > > > http://www.open-std.org/jtc1/sc22/wg21/docs/p

[PATCH] D119409: [C++20] [Modules] Remain variable's definition in module interface

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/CXX/modules-ts/basic/basic.def.odr/p4/module.cpp:5 // CHECK-DAG: @extern_var_exported = external {{(dso_local )?}}global -// CHECK-DAG: @inline_var_exported = linkonce_odr {{(dso_local )?}}global +// CHECK-DAG: @inline_var_e

[PATCH] D118587: [C++20][Modules][4/8] Handle generation of partition implementation CMIs.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. with the assert fixed Comment at: clang/lib/Sema/SemaModule.cpp:119 +default: + assert(0 && "how did we get a partition type set?"); +} llvm

[PATCH] D119823: [Modules] Add module structure output to -module-file-info.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/Modules/module-file-info-cxx20.cpp:26 + +#if TU == 1 + iains wrote: > urnathan wrote: > > urnathan wrote: > > > ChuanqiXu wrote: > > > > iains wrote: > > > > > ChuanqiXu wrote: > > > > > > According to [[ >

[PATCH] D118598: [C++20][Modules][7/8] Find the primary interface name for a module.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/include/clang/Basic/Module.h:520-522 + /// Get the primary module interface name from a partition. + + std::string getPrimaryModuleInterfaceName() const { stray blank line? Comment at: clang/i

[PATCH] D118598: [C++20][Modules][7/8] Find the primary interface name for a module.

2022-02-16 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/include/clang/Basic/Module.h:522 + + std::string getPrimaryModuleInterfaceName() const { +std::string::size_type pos = Name.find(':'); Is it possible to return a StringRef rather than a copy? Repository:

[PATCH] D119409: [C++20] [Modules] Remain internal-linkage variables in module interface unit

2022-02-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/test/CXX/modules-ts/basic/basic.def.odr/p4/module.cpp:5 // CHECK-DAG: @extern_var_exported = external {{(dso_local )?}}global -// CHECK-DAG: @inline_var_exported = linkonce_odr {{(dso_local )?}}global +// CHECK-DAG: @inline_var_e

[PATCH] D118034: [C++20] [Modules] Don't complain about duplicated default template argument across modules

2022-02-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Sema/SemaTemplate.cpp:2658-2682 +Expr::EvalResult EVRX, EVRY; +if (!DefaultArgumentX->EvaluateAsConstantExpr(EVRX, C) || +!DefaultArgumentY->EvaluateAsConstantExpr(EVRY, C)) + return false; + +APValue

[PATCH] D118586: [C++20][Modules][3/8] Initial handling for module partitions.

2022-02-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Sema/SemaModule.cpp:177 + if (IsPartition) { +ModuleName += ":"; +ModuleName += stringFromPath(Partition); iains wrote: > ChuanqiXu wrote: > > I chose '-' in my implementation since here ModuleName re

[PATCH] D118586: [C++20][Modules][3/8] Initial handling for module partitions.

2022-02-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. thanks Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118586/new/ https://reviews.llvm.org/D118586 _

[PATCH] D118034: [C++20] [Modules] Don't complain about duplicated default template argument across modules

2022-02-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Sema/SemaTemplate.cpp:2658-2682 +Expr::EvalResult EVRX, EVRY; +if (!DefaultArgumentX->EvaluateAsConstantExpr(EVRX, C) || +!DefaultArgumentY->EvaluateAsConstantExpr(EVRY, C)) + return false; + +APValue

[PATCH] D118034: [C++20] [Modules] Don't complain about duplicated default template argument across modules

2022-02-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Sema/SemaTemplate.cpp:2658-2682 +Expr::EvalResult EVRX, EVRY; +if (!DefaultArgumentX->EvaluateAsConstantExpr(EVRX, C) || +!DefaultArgumentY->EvaluateAsConstantExpr(EVRY, C)) + return false; + +APValue

[PATCH] D114714: [C++20][Modules][2/8] Add enumerations for partition modules and stream them.

2022-02-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. please remind me when this is committed that I'll need to adjust D118352 -- at the moment that's searching for ':' to determine partitionness Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D122663: Mark identifier prefixes as substitutable

2022-04-25 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. [was out last week] It seems the demangler already gets this right, probably because it just looks like a regular nested name Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122663/new/ https://reviews.llvm.org/D122663 __

[PATCH] D122663: Mark identifier prefixes as substitutable

2022-05-03 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/AST/ItaniumMangle.cpp:6031 +bool CXXNameMangler::mangleSubstitution(NestedNameSpecifier *NNS) { + NNS = Context.getASTContext().getCanonicalNestedNameSpecifier(NNS); + return mangleSubstitution(reinterpret_cast(NNS)); --

[PATCH] D122663: Mark identifier prefixes as substitutable

2022-05-03 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/AST/ItaniumMangle.cpp:6031 +bool CXXNameMangler::mangleSubstitution(NestedNameSpecifier *NNS) { + NNS = Context.getASTContext().getCanonicalNestedNameSpecifier(NNS); + return mangleSubstitution(reinterpret_cast(NNS)); --

[PATCH] D125085: [clang-format] Correctly handle SpaceBeforeParens for builtins.

2022-05-06 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. cool Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125085/new/ https://reviews.llvm.org/D125085 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cg

[PATCH] D124946: [clang] serialize ORIGINAL_PCH_DIR relative to BaseDirectory

2022-05-09 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. Looks good to me, but perhaps leave it a few days for others to comment (my familiarity with this code is low). I do know people want relocatable outputs though. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124946/new/

[PATCH] D124874: [clang] add -fmodule-file-home-is-cwd

2022-05-09 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Serialization/ASTWriter.cpp:1231-1236 +SmallString<128> BaseDir(CWD->getName()); +cleanPathForOutput(Context.getSourceManager().getFileManager(), BaseDir); +BaseDirectory.assign(BaseDir.begin(), BaseDir.end()); +

[PATCH] D124874: [clang] add -fmodule-file-home-is-cwd

2022-05-10 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Serialization/ASTWriter.cpp:1231-1236 +SmallString<128> BaseDir(CWD->getName()); +cleanPathForOutput(Context.getSourceManager().getFileManager(), BaseDir); +BaseDirectory.assign(BaseDir.begin(), BaseDir.end()); +

[PATCH] D125272: [clang] Add -fcheck-new support

2022-05-10 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:15440 + // + // However, -fcheck-new violates this possible assumption, so don't add + // NonNull when that is enabled. 'invalidates' or 'negates' are better words here. Repository: rG

[PATCH] D124938: [clang] serialize SUBMODULE_TOPHEADER relative to BaseDirectory

2022-05-10 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. lgtm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124938/new/ https://reviews.llvm.org/D124938 ___

[PATCH] D124874: [clang] add -fmodule-file-home-is-cwd

2022-05-11 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124874/new/ https://reviews.llvm.org/D124874

[PATCH] D124946: [clang] serialize ORIGINAL_PCH_DIR relative to BaseDirectory

2022-05-12 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan accepted this revision. urnathan added a comment. This revision is now accepted and ready to land. good to go, thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124946/new/ https://reviews.llvm.org/D124946

[PATCH] D125535: [clang][NFC] Cleanup some coroutine tests

2022-05-16 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG80bebbc7cb77: [clang][NFC] Cleanup some coroutine tests (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D126189: [C++20][Modules] Build module static initializers per P1874R1.

2022-05-23 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/CodeGen/CGDeclCXX.cpp:626-627 + // We create the function, even if it is empty, since an importer of this + // module will refer to it unconditionally (there is no way for an importer + // to know if the function could be o

[PATCH] D122741: [clang] Module global init mangling

2022-05-23 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa1dcfb75ea8c: [clang] Module global init mangling (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits. Changed prior to commit: https://reviews.llvm.org/D122741

[PATCH] D102480: [clang][NFC] remove unused return value

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG0566f979619c: [clang][NFC] remove unused return value (authored by urnathan). Herald added a project: clang. Herald added a subscriber: cfe-commits.

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345416. urnathan added a comment. Herald added subscribers: cfe-commits, usaxena95, kadircet. Herald added a project: clang-tools-extra. Address the build failure --thanks for explaining, it wasn;t clear what else I should try and build. Grepping showed no

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345426. urnathan added a comment. I stupidly tested that on the stack, not just the first diff. This removes the reference to bits from a later patch CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101777/new/ https://reviews.llvm.org/D101777 File

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan marked 5 inline comments as done. urnathan added inline comments. Comment at: clang/lib/Sema/SemaDeclCXX.cpp:12370 // If we weren't able to compute a valid scope, it might validly be a // dependent class scope or a dependent enumeration unscoped scope. If

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345487. urnathan added a comment. Address Bruno's comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100276/new/ https://reviews.llvm.org/D100276 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/Sema/Sema.h cla

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan marked an inline comment as done. urnathan added inline comments. Comment at: clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p3.cpp:20 class C { +public: int g(); bruno wrote: > bruno wrote: > > > The change to > > > clang/test/CXX/dcl.dcl/b

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345491. urnathan added a comment. Herald added subscribers: cfe-commits, usaxena95, kadircet. Herald added a project: clang-tools-extra. reupload diff CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345500. urnathan added a comment. Let's try again. Logically this is separate from patch 3, but because that and this touch adjacent lines in the diagnostics file, we need to say patch 3 is a dependency, otherwise we get a conflict. CHANGES SINCE LAST AC

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. I don't understand why the build bot is failing to apply the precursor D101777 diff. that diff is marked as ok by the build bot. How can I find the actual error the build bot is encountering? CHANGES SINCE LAST ACTION https://rev

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345520. urnathan added a comment. unbreaking bot testing of D102241 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101777/new/ https://reviews.llvm.org/D101777 Files: clang-tools-extra/clangd/FindTarget.cpp cl

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-14 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345522. urnathan added a comment. force bot rebuild CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/ASTContext.h clang/include/

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345848. urnathan added a comment. Add serialization test and fix bug so found (thanks Bruno!) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/inclu

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345957. urnathan added a comment. rebased onto 3cdd05e519dd , (trying to fix patch 4's precommit failure) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101777/new/ https://revie

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-05-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345959. urnathan edited the summary of this revision. urnathan added a comment. rebased, trying to resolve patch 4's bot fail CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100276/new/ https://reviews.llvm.org/D100276 Files: clang/include/clang/B

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345960. urnathan added a comment. rebased, trying to resolve bot failure, again CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/A

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-05-17 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 345973. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100276/new/ https://reviews.llvm.org/D100276 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/Sema/Sema.h clang/lib/Sema/SemaDeclCXX.cpp clang/lib/Sema/SemaTemp

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-05-18 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. good, it appears the patch bot fail is fixed -- it seems unhappy with non-tree-like dependency graphs, and tries to apply each reachable patch as many times as it is reachable :( The data race failure seems entirely unconnected with this patch -- please correct me if I

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-18 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 346107. urnathan added a comment. updating to reset dependency graph and coax build bot into working CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clan

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-18 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:4654 + + return ImportUsingShadowDecls(D, ToUsingEnum); } martong wrote: > Could it work if you imported the shadow declarations **before** creating the > `UsingEnumDecl`? I yes, then th

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-18 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:4623 - Expected ToUsingOrErr = import(D->getUsingDecl()); - if (!ToUsingOrErr) -return ToUsingOrErr.takeError(); + Expected ToIntroducerOrErr = import(D->getIntroducer()); + if (!ToIntroducerOrErr

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-19 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 346421. urnathan added a comment. Added ASTmatchers for UsingEnumDecl along with unit-tests (both of which I was previously unaware of) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tool

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-19 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:4623 - Expected ToUsingOrErr = import(D->getUsingDecl()); - if (!ToUsingOrErr) -return ToUsingOrErr.takeError(); + Expected ToIntroducerOrErr = import(D->getIntroducer()); + if (!ToIntroducerOrErr

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-21 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan marked an inline comment as done. urnathan added inline comments. Comment at: clang/lib/Sema/SemaDeclCXX.cpp:11632 + // As with enum-decls, we ignore attributes for now. + + auto *Enum = cast(DS.getRepAsDecl()); bruno wrote: > Remove this empty line. Y

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-21 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 346985. urnathan added a comment. Fix nits CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/ASTContext.h clang/include/clang/AST

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-24 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 347401. urnathan added a comment. Addressing Davrec's comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101777/new/ https://reviews.llvm.org/D101777 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/DeclCXX.h clang/

[PATCH] D101777: [clang] p1099 1/5: [NFC] Break out BaseUsingDecl from UsingDecl

2021-05-24 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan marked 2 inline comments as done. urnathan added inline comments. Comment at: clang/include/clang/AST/DeclCXX.h:3390 ConstructorUsingShadowDecl(ASTContext &C, DeclContext *DC, SourceLocation Loc, - UsingDecl *Using, NamedDecl *Target, +

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-05-24 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 347403. urnathan added a comment. rebased CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100276/new/ https://reviews.llvm.org/D100276 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/Sema/Sema.h clang/lib/Sema/SemaD

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-24 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 347405. urnathan added a comment. Address davrec's comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/ASTContext.h clang/

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-05-24 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 347406. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/ASTContext.h clang/include/clang/AST/DeclCXX.h clang/include/clang/AST/

[PATCH] D102650: Old work on P0388. For reference in D102645. Not for review / commit.

2021-05-25 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan added a comment. dblaikie, do you know if there's a way to do it outside of arc? (for reasons, I've not got arc to work from inside work). I tried not setting a reviewer, but then that got autofilled. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-06-01 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 349044. urnathan added a comment. Rebase and fix conflict CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100276/new/ https://reviews.llvm.org/D100276 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/Sema/Sema.h clan

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-06-01 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 349045. urnathan added a comment. rebase and fix conflict CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/ASTContext.h clang/in

[PATCH] D103258: [clang] Fix ICE with typeid & polymorphic class (pr50497)

2021-06-01 Thread Nathan Sidwell via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGc138f3ce5c70: [clang] Fix ICE with typeid & polymorphic class (pr50497) (authored by urnathan). Herald added a project: clang. Herald added a subscri

  1   2   >