[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

Iain Sandoe via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 4 02:07:01 PDT 2022


iains added inline comments.


================
Comment at: clang/lib/Sema/SemaDecl.cpp:9363-9365
+        Module *M = NewFD->getOwningModule();
+        if (!M || M->isGlobalModule())
+          NewFD->setImplicitlyInline();
----------------
iains wrote:
> ChuanqiXu wrote:
> > nit: this is not  required.
> well, the logic is required ;) .. you have suggested a different way to write..
actually, I think you meant `!NewFD->getOwningModule() || NewFD->getOwningModule()->isGlobalModule()` but I've pulled the test out so that it's only done once.



Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D129045



More information about the cfe-commits mailing list