[PATCH] D127187: [C++20] [Modules] Implement AllAdditionalTUReachable

Chuanqi Xu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jul 14 00:07:58 PDT 2022


ChuanqiXu abandoned this revision.
ChuanqiXu added a comment.

In D127187#3650824 <https://reviews.llvm.org/D127187#3650824>, @iains wrote:

> Hi @ChuanqiXu, 
> I have no comment on the technical content of the patch (it looks reasonable to me).
>
> However, I wonder if we should be supplying this option at all because in:
> https://eel.is/c++draft/module#reach-2
> note2 says "[Note 2: It is advisable to avoid depending on the reachability of any additional translation units in programs intending to be portable. — end note]"
>
> So by providing the option, we are effectively giving users an easy mechanism to make non-portable programs (and I'm fairly sure that would mean that they would not have the same characteristics between clang and GCC with this); 
> So I'd like to know what (preferably real-world) code motivates the addition of this option.

Oh, I see. In fact, I didn't meet any motivated case before. The motivation of the revision is that we feel like it might be better to add an option in D113545 <https://reviews.llvm.org/D113545>. But now I feel like the option is not good indeed. And this one is relatively easy to implement. So we could re-land this if we find it is useful someday.


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

https://reviews.llvm.org/D127187



More information about the cfe-commits mailing list