[ELF] Pass Ctx & to InputFiles
This commit is contained in:
@@ -352,7 +352,7 @@ void ScriptParser::addFile(StringRef s) {
|
||||
ctx.driver.addFile(s, /*withLOption=*/false);
|
||||
} else {
|
||||
// Finally, search in the list of library paths.
|
||||
if (std::optional<std::string> path = findFromSearchPaths(s))
|
||||
if (std::optional<std::string> path = findFromSearchPaths(ctx, s))
|
||||
ctx.driver.addFile(saver().save(*path), /*withLOption=*/true);
|
||||
else
|
||||
setError("unable to find " + s);
|
||||
@@ -400,8 +400,8 @@ void ScriptParser::readInclude() {
|
||||
return;
|
||||
}
|
||||
|
||||
if (std::optional<std::string> path = searchScript(name)) {
|
||||
if (std::optional<MemoryBufferRef> mb = readFile(*path)) {
|
||||
if (std::optional<std::string> path = searchScript(ctx, name)) {
|
||||
if (std::optional<MemoryBufferRef> mb = readFile(ctx, *path)) {
|
||||
buffers.push_back(curBuf);
|
||||
curBuf = Buffer(ctx, *mb);
|
||||
mbs.push_back(*mb);
|
||||
|
||||
Reference in New Issue
Block a user