aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-07-01 20:03:04 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-07-01 20:03:04 +0000
commitc88a88f6f7672b6bb831dce9da4acfa0c846975f (patch)
tree8be362c8496df198b8be116b56ef6df104ab70cc /include
parent961743326fd18776f897bf4461345dba680ef637 (diff)
Driver: Move Compilation::Execute to Driver::ExecuteCompilation.
- The Compilation is just a helper class, it shouldn't have that amount of logic in it. - No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@74634 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/clang/Driver/Compilation.h12
-rw-r--r--include/clang/Driver/Driver.h8
2 files changed, 14 insertions, 6 deletions
diff --git a/include/clang/Driver/Compilation.h b/include/clang/Driver/Compilation.h
index 0e66796a6e..3ec221f41d 100644
--- a/include/clang/Driver/Compilation.h
+++ b/include/clang/Driver/Compilation.h
@@ -69,6 +69,11 @@ public:
const ActionList &getActions() const { return Actions; }
JobList &getJobs() { return Jobs; }
+ const JobList &getJobs() const { return Jobs; }
+
+ const ArgStringList &getTempFiles() const { return TempFiles; }
+
+ const ArgStringList &getResultFiles() const { return ResultFiles; }
/// getArgsForToolChain - Return the derived argument list for the
/// tool chain \arg TC (or the default tool chain, if TC is not
@@ -89,11 +94,6 @@ public:
return Name;
}
- /// Execute - Execute the compilation jobs and return an
- /// appropriate exit code.
- int Execute() const;
-
-private:
/// CleanupFileList - Remove the files in the given list.
///
/// \param IssueErrors - Report failures as errors.
@@ -120,7 +120,7 @@ private:
/// ExecuteJob - Execute a single job.
///
/// \param FailingCommand - For non-zero results, this will be set to the
- /// Command which failed, if any.
+ /// Command which failed.
/// \return The accumulated result code of the job.
int ExecuteJob(const Job &J, const Command *&FailingCommand) const;
};
diff --git a/include/clang/Driver/Driver.h b/include/clang/Driver/Driver.h
index 66e3b97875..c0def2bcca 100644
--- a/include/clang/Driver/Driver.h
+++ b/include/clang/Driver/Driver.h
@@ -161,6 +161,14 @@ public:
/// \arg C - The compilation that is being built.
void BuildJobs(Compilation &C) const;
+ /// ExecuteCompilation - Execute the compilation according to the command line
+ /// arguments and return an appropriate exit code.
+ ///
+ /// This routine handles additional processing that must be done in addition
+ /// to just running the subprocesses, for example reporting errors, removing
+ /// temporary files, etc.
+ int ExecuteCompilation(const Compilation &C) const;
+
/// @}
/// @name Helper Methods
/// @{