[PATCH] D158709: [Headers][Modules] Make separate headers for the stdarg.h and stddef.h pieces so that they can be modularized

2023-08-25 Thread Ian Anderson via Phabricator via cfe-commits
iana added a comment. In D158709#4617295 , @aaron.ballman wrote: > I'm a bit concerned about the impact on (non-modules) build time performance. > This splits stddef.h and stdarg.h into needing to open 14 different files > instead of 2. Hopefully that'

[PATCH] D158709: [Headers][Modules] Make separate headers for the stdarg.h and stddef.h pieces so that they can be modularized

2023-08-25 Thread Ian Anderson via Phabricator via cfe-commits
iana updated this revision to Diff 553677. iana added a comment. Modules don't support the #include #undef #include pattern to redefine macros, the second include has no effect. Move the #undef of NULL into __stddef_null.h so that the textual behavior is preserved, but the module behavior doesn'

[PATCH] D158709: [Headers][Modules] Make separate headers for the stdarg.h and stddef.h pieces so that they can be modularized

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana added a comment. In D158709#4621199 , @aaron.ballman wrote: > At a high-level (not just for this patch, but for the entire series): is this > need specific to your downstream or is this a more general need? e.g., should > this complexity be kept d

[PATCH] D159018: [clang][modules] Add a c23 module feature

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana created this revision. iana added reviewers: ChuanqiXu, Bigcheese, v.g.vassilev, aaron.ballman. Herald added a subscriber: ributzka. Herald added a project: All. iana requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add a c23 module fea

[PATCH] D159018: [clang][modules] Add a c23 module feature

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana added a comment. Would we want to back port this to llvm 17? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D159018/new/ https://reviews.llvm.org/D159018 ___ cfe-commits mailing list cfe-commits@lists

[PATCH] D159018: [clang][modules] Add a c23 module feature

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana updated this revision to Diff 554158. iana added a comment. remove the extra #endif (which oddly didn't produce an error locally so I must've ran the tests wrong the first time...) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D159018/new/ htt

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana created this revision. iana added reviewers: aaron.ballman, rsmith, efriedma, ldionne, ChuanqiXu, Bigcheese, vsapsai, benlangmuir, dexonsmith. Herald added a subscriber: ributzka. Herald added a project: All. iana requested review of this revision. Herald added a project: clang. Herald added

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana updated this revision to Diff 554183. iana added a comment. Remove the module cache before running the stdarg/stddef unit tests in module mode Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D159064/new/ https://reviews.llvm.org/D159064 Files:

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana updated this revision to Diff 554193. iana added a comment. Add `@import` tests for all of the new modules Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D159064/new/ https://reviews.llvm.org/D159064 Files: clang/lib/Headers/__stddef_max_alig

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-08-28 Thread Ian Anderson via Phabricator via cfe-commits
iana added inline comments. Comment at: clang/lib/Headers/__stddef_null.h:14 + * __need_NULL and rely on stddef.h to redefine NULL to the correct value again. + * Modules don't support redefining macros like that, but support that pattern + * in the non-modules case. ---

[PATCH] D159018: [clang][modules] Add a c23 module feature

2023-08-29 Thread Ian Anderson via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGadb68c979d84: [clang][modules] Add a c23 module feature (authored by iana). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D159018/new/ https://reviews.llvm.o

[PATCH] D158709: [Headers][Modules] Make separate headers for the stdarg.h and stddef.h pieces so that they can be modularized

2023-08-30 Thread Ian Anderson via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG680da4b5d7ec: [Headers][Modules] Make separate headers for the stdarg.h and stddef.h pieces… (authored by iana). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-08-30 Thread Ian Anderson via Phabricator via cfe-commits
iana marked an inline comment as done. iana added inline comments. Comment at: clang/lib/Headers/__stddef_null.h:14 + * __need_NULL and rely on stddef.h to redefine NULL to the correct value again. + * Modules don't support redefining macros like that, but support that pattern +

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-08-30 Thread Ian Anderson via Phabricator via cfe-commits
iana updated this revision to Diff 554832. iana marked an inline comment as done. iana added a comment. The nullptr_t submodule can't require c23 because it needs to be used in C++ in some cases too. Remove the `requires` from the module map and add a C23 guard to the header. Repository: rG

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-08-30 Thread Ian Anderson via Phabricator via cfe-commits
iana updated this revision to Diff 554882. iana added a comment. Update Module::directlyUses Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D159064/new/ https://reviews.llvm.org/D159064 Files: clang/lib/Basic/Module.cpp clang/lib/Headers/__stdde

[PATCH] D159312: [Headers] Remove a space in NULL define

2023-08-31 Thread Ian Anderson via Phabricator via cfe-commits
iana accepted this revision. iana added a comment. This revision is now accepted and ready to land. Can you add a comment that says the spacing is important please? Although why the heck is musl declaring NULL in stdio.h? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:

[PATCH] D159064: [Modules] Make clang modules for the C standard library headers

2023-09-01 Thread Ian Anderson via Phabricator via cfe-commits
iana added a comment. Ah, the tests are failing because some of them are putting the builtin headers in other modules. This is going to need the "optionally ignore the builtin modules" change first then. I almost have that one finished. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D103930: [clang][HeaderSearch] Fix implicit module when using header maps

2023-05-10 Thread Ian Anderson via Phabricator via cfe-commits
iana added inline comments. Comment at: clang/test/Modules/implicit-module-header-maps.cpp:52 +//header and trip a `#error`, or +// 2) header maps aren't usesd, as the header name doesn't exist and relies on +//the header map to remap it to the real header. --

[PATCH] D103930: [clang][HeaderSearch] Fix implicit module when using header maps

2023-05-10 Thread Ian Anderson via Phabricator via cfe-commits
iana added a comment. I wonder if clang should have better module interaction with the header maps produced by Xcode, or if Xcode should produce better header maps to work with clang. Or are you having problems with header maps outside of Xcode? Repository: rG LLVM Github Monorepo CHANGES S

[PATCH] D140250: Define NULL in its own header

2022-12-16 Thread Ian Anderson via Phabricator via cfe-commits
iana created this revision. iana added reviewers: ributzka, vsapsai, Bigcheese. Herald added a subscriber: mstorsjo. Herald added a project: All. iana requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Make a new header to define NULL so that

[PATCH] D140250: Define NULL in its own header

2022-12-16 Thread Ian Anderson via Phabricator via cfe-commits
iana added inline comments. Comment at: clang/lib/Headers/__stddef_null.h:15 +#ifdef __cplusplus +#if !defined(__MINGW32__) && !defined(_MSC_VER) +#define NULL __null `arc lint` wanted to remove all of the indentation that was in stddef.h. Repository: rG LLVM

[PATCH] D118311: [Clang][ModuleMap] Add conditional parsing via requires block declaration

2022-01-27 Thread Ian Anderson via Phabricator via cfe-commits
iana added inline comments. Comment at: clang/docs/Modules.rst:651 + +requires cplusplus { + header "vector" Is there any kind of `else` syntax here? Or do you just use `!whatever` for the else? Is something like this valid? ``` requires cplusplus11 {

[PATCH] D118311: [Clang][ModuleMap] Add conditional parsing via requires block declaration

2022-01-27 Thread Ian Anderson via Phabricator via cfe-commits
iana added inline comments. Comment at: clang/docs/Modules.rst:651 + +requires cplusplus { + header "vector" Bigcheese wrote: > iana wrote: > > Is there any kind of `else` syntax here? Or do you just use `!whatever` for > > the else? Is something like t

[PATCH] D118311: [Clang][ModuleMap] Add conditional parsing via requires block declaration

2022-02-01 Thread Ian Anderson via Phabricator via cfe-commits
iana added inline comments. Comment at: clang/include/clang/Basic/Module.h:249 + /// language options has the given feature. + static bool hasFeature(StringRef Feature, const LangOptions &LangOpts, + const TargetInfo &Target); Is `static

<    1   2