diff options
Diffstat (limited to 'lib/Basic/Module.cpp')
-rw-r--r-- | lib/Basic/Module.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/lib/Basic/Module.cpp b/lib/Basic/Module.cpp index 0b7832636943..3d1a40db5ea2 100644 --- a/lib/Basic/Module.cpp +++ b/lib/Basic/Module.cpp @@ -418,12 +418,8 @@ void Module::print(raw_ostream &OS, unsigned Indent) const { OS.indent(Indent + 2); OS << "export "; printModuleId(OS, UnresolvedExports[I].Id); - if (UnresolvedExports[I].Wildcard) { - if (UnresolvedExports[I].Id.empty()) - OS << "*"; - else - OS << ".*"; - } + if (UnresolvedExports[I].Wildcard) + OS << (UnresolvedExports[I].Id.empty() ? "*" : ".*"); OS << "\n"; } @@ -486,12 +482,13 @@ void Module::print(raw_ostream &OS, unsigned Indent) const { OS << "}\n"; } -void Module::dump() const { +LLVM_DUMP_METHOD void Module::dump() const { print(llvm::errs()); } void VisibleModuleSet::setVisible(Module *M, SourceLocation Loc, VisibleCallback Vis, ConflictCallback Cb) { + assert(Loc.isValid() && "setVisible expects a valid import location"); if (isVisible(M)) return; |