}
// Inferred modules must have umbrella headers.
- if (!Failed && !ActiveModule->getTopLevelModule()->UmbrellaHeader) {
+ if (!Failed && !ActiveModule->UmbrellaHeader) {
Diags.Report(StarLoc, diag::err_mmap_inferred_no_umbrella);
Failed = true;
}
// Check for redefinition of an inferred module.
- if (!Failed && ActiveModule->getTopLevelModule()->InferSubmodules) {
+ if (!Failed && ActiveModule->InferSubmodules) {
Diags.Report(StarLoc, diag::err_mmap_inferred_redef);
- if (ActiveModule->getTopLevelModule()->InferredSubmoduleLoc.isValid())
- Diags.Report(ActiveModule->getTopLevelModule()->InferredSubmoduleLoc,
+ if (ActiveModule->InferredSubmoduleLoc.isValid())
+ Diags.Report(ActiveModule->InferredSubmoduleLoc,
diag::note_mmap_prev_definition);
Failed = true;
}
}
// Note that we have an inferred submodule.
- Module *TopModule = ActiveModule->getTopLevelModule();
- TopModule->InferSubmodules = true;
- TopModule->InferredSubmoduleLoc = StarLoc;
- TopModule->InferExplicitSubmodules = Explicit;
+ ActiveModule->InferSubmodules = true;
+ ActiveModule->InferredSubmoduleLoc = StarLoc;
+ ActiveModule->InferExplicitSubmodules = Explicit;
// Parse the opening brace.
if (!Tok.is(MMToken::LBrace)) {
case MMToken::ExportKeyword: {
consumeToken();
if (Tok.is(MMToken::Star))
- TopModule->InferExportWildcard = true;
+ ActiveModule->InferExportWildcard = true;
else
Diags.Report(Tok.getLocation(),
diag::err_mmap_expected_export_wildcard);
}
// Test header cross-subframework include pattern.
-#include <DependsOnModule/../Frameworks/SubFramework.framework/Headers/Other.h> // expected-warning{{treating #include as an import of module 'DependsOnModule.SubFramework'}}
+#include <DependsOnModule/../Frameworks/SubFramework.framework/Headers/Other.h> // expected-warning{{treating #include as an import of module 'DependsOnModule.SubFramework.Other'}}
void testSubframeworkOtherAgain() {
double *sfo1 = sub_framework_other;