diff --git a/lld/MachO/InputFiles.cpp b/lld/MachO/InputFiles.cpp --- a/lld/MachO/InputFiles.cpp +++ b/lld/MachO/InputFiles.cpp @@ -339,10 +339,9 @@ } // Checks if the version specified in `cmd` is compatible with target -// version in `config`. IOW, check if cmd's version >= config's version. +// version. IOW, check if cmd's version >= config's version. static bool hasCompatVersion(const InputFile *input, - const build_version_command *cmd, - const Configuration *config) { + const build_version_command *cmd) { if (config->target.Platform != static_cast(cmd->platform)) { error(toString(input) + " has platform " + @@ -512,7 +511,7 @@ if (const auto *cmd = findCommand(hdr, LC_BUILD_VERSION)) { - if (!hasCompatVersion(this, cmd, config)) + if (!hasCompatVersion(this, cmd)) return; } @@ -673,7 +672,7 @@ if (const build_version_command *cmd = findCommand(hdr, LC_BUILD_VERSION)) { - if (!hasCompatVersion(this, cmd, config)) + if (!hasCompatVersion(this, cmd)) return; }