[Driver] Remove the notion of Tools, turn ToolChain into an Action visitor.

The "Tool" abstraction wasn't buying us enough to deserve the added
complexity. Now a ToolChain turns Actions into Jobs, and every helper
tool is searched for relative to Swift first. Much simpler.

Swift SVN r31563
This commit is contained in:
Jordan Rose
2015-08-28 23:12:33 +00:00
parent 409010741e
commit de2ecbb80e
25 changed files with 1168 additions and 1451 deletions

View File

@@ -17,7 +17,6 @@
#include "swift/Driver/Compilation.h"
#include "swift/Driver/Driver.h"
#include "swift/Driver/Job.h"
#include "swift/Driver/Tool.h"
#include "swift/Frontend/Frontend.h"
using namespace swift;
@@ -57,7 +56,7 @@ swift::driver::createCompilerInvocation(ArrayRef<const char *> ArgList,
}
const Job *Cmd = *CompileCommands.begin();
if (Cmd->getCreator().getName() != "swift") {
if (Cmd->getArguments().front() != "-frontend") {
Diags.diagnose(SourceLoc(), diag::error_expected_frontend_command);
return nullptr;
}