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

Iain Sandoe via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 17 06:35:25 PST 2022


iains added inline comments.


================
Comment at: clang/test/Modules/cxx20-10-1-ex1.cpp:7-8
+
+// RUN: %clang_cc1 -std=c++20 -emit-module-interface -D TU=1 -x c++ %s \
+// RUN:  -o %t/A_Internals.pcm
+
----------------
ChuanqiXu wrote:
> In my implementation, I replace ':' to '-' in pcm filename. I do so since I remember this is the behavior of GCC. I think '-' is better than '_' since '_' is possible to occur in name.
> 
> And I am surprised that the compiler wouldn't complain about that it couldn't find the corresponding pcm. Since I don't see corresponding code so far.
The filename could/should be completely decoupled from the module name; changing the filenames to something randomly chosen should make no difference to the tests passing.

I made a comment on why/how this works in 3/8 in reply a similar comment made there (essentially the pairing of module-name and filename is something known by the lmodule loader and/or the header search mechanisms - it is not something that Sema needs to know).




================
Comment at: clang/test/Modules/cxx20-10-1-ex1.cpp:21
+
+#if TU == 1
+
----------------
urnathan wrote:
> I think I'm getting used to this idiom, or maybe Stockholm has kicked in?
we are all hostage to some style decisions made by others?
FAOD, the idiom is not my device, I plagiarised ...


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D118587/new/

https://reviews.llvm.org/D118587



More information about the cfe-commits mailing list