This is an archive of the discontinued LLVM Phabricator instance.

[clang][deps] Minor ModuleDepCollector refactorings NFC
ClosedPublic

Authored by benlangmuir on Aug 24 2022, 3:44 PM.

Details

Summary
  • Factor module map and module file path functions out
  • Use a secondary mapping to lookup module deps by ID instead of the preprocessor module map.
  • Sink DirectPrebuiltModularDeps into MDC.

Diff Detail

Event Timeline

benlangmuir created this revision.Aug 24 2022, 3:44 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 24 2022, 3:44 PM
benlangmuir requested review of this revision.Aug 24 2022, 3:44 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 24 2022, 3:44 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
jansvoboda11 accepted this revision.Aug 24 2022, 3:56 PM

LGTM with a nit.

clang/lib/Tooling/DependencyScanning/ModuleDepCollector.cpp
277

Nit: I think you should be able to drop std::make_pair() and use brace-initialization. Also applies to the other call to insert above.

This revision is now accepted and ready to land.Aug 24 2022, 3:56 PM
This revision was landed with ongoing or failed builds.Aug 25 2022, 6:58 AM
This revision was automatically updated to reflect the committed changes.