summaryrefslogtreecommitdiffstats
path: root/lld/lib/Core
diff options
context:
space:
mode:
Diffstat (limited to 'lld/lib/Core')
-rw-r--r--lld/lib/Core/InputGraph.cpp6
-rw-r--r--lld/lib/Core/Resolver.cpp11
2 files changed, 8 insertions, 9 deletions
diff --git a/lld/lib/Core/InputGraph.cpp b/lld/lib/Core/InputGraph.cpp
index 730a958158e..39d2b193b7c 100644
--- a/lld/lib/Core/InputGraph.cpp
+++ b/lld/lib/Core/InputGraph.cpp
@@ -15,9 +15,9 @@
using namespace lld;
-ErrorOr<File &> InputGraph::nextFile() {
- // When nextFile() is called for the first time, _currentInputElement is not
- // initialized. Initialize it with the first element of the input graph.
+ErrorOr<File &> InputGraph::getNextFile() {
+ // When getNextFile() is called for the first time, _currentInputElement is
+ // not initialized. Initialize it with the first element of the input graph.
if (_currentInputElement == nullptr) {
ErrorOr<InputElement *> elem = getNextInputElement();
if (elem.getError() == InputGraphError::no_more_elements)
diff --git a/lld/lib/Core/Resolver.cpp b/lld/lib/Core/Resolver.cpp
index 69688fe78ff..1b40bd37dcc 100644
--- a/lld/lib/Core/Resolver.cpp
+++ b/lld/lib/Core/Resolver.cpp
@@ -65,7 +65,7 @@ void Resolver::handleFile(const File &file) {
// Notify the input file manager of the fact that we have made some progress
// on linking using the current input file. It may want to know the fact for
// --start-group/--end-group.
- _context.inputGraph().notifyProgress();
+ _context.getInputGraph().notifyProgress();
}
void Resolver::forEachUndefines(UndefCallback callback,
@@ -260,19 +260,18 @@ void Resolver::addAtoms(const std::vector<const DefinedAtom *> &newAtoms) {
doDefinedAtom(*newAtom);
}
-// Keep adding atoms until _context.nextFile() returns an error. This function
-// is where undefined atoms are resolved.
+// Keep adding atoms until _context.getNextFile() returns an error. This
+// function is where undefined atoms are resolved.
bool Resolver::resolveUndefines() {
ScopedTask task(getDefaultDomain(), "resolveUndefines");
for (;;) {
- ErrorOr<File &> file = _context.inputGraph().nextFile();
+ ErrorOr<File &> file = _context.getInputGraph().getNextFile();
error_code ec = file.getError();
if (ec == InputGraphError::no_more_files)
return true;
if (!file) {
- llvm::errs() << "Error occurred in nextFile: "
- << ec.message() << "\n";
+ llvm::errs() << "Error occurred in getNextFile: " << ec.message() << "\n";
return false;
}
OpenPOWER on IntegriCloud