diff options
author | Daniel Dunbar <daniel@zuster.org> | 2009-07-01 19:02:28 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2009-07-01 19:02:28 +0000 |
commit | cae087e164e94e4286c11bf694dd0ff88f295302 (patch) | |
tree | ac70032590c62a21da250b32a40366102a2067b7 /include | |
parent | 4d374d4a4832a01d5d3b75c59cb1567e60df41e7 (diff) |
Driver: Add Source argument for Commands to hold the Action which caused a
Command to be generated, to support more advanced diagnostics.
- No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@74627 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/clang/Driver/Job.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/include/clang/Driver/Job.h b/include/clang/Driver/Job.h index f60f514641..a23babdbb3 100644 --- a/include/clang/Driver/Job.h +++ b/include/clang/Driver/Job.h @@ -52,6 +52,9 @@ public: /// Command - An executable path/name and argument vector to /// execute. class Command : public Job { + /// Source - The action which caused the creation of this job. + const Action &Source; + /// The executable to run. const char *Executable; @@ -60,9 +63,14 @@ class Command : public Job { ArgStringList Arguments; public: - Command(const char *_Executable, const ArgStringList &_Arguments); + Command(const Action &_Source, const char *_Executable, + const ArgStringList &_Arguments); + + /// getSource - Return the Action which caused the creation of this job. + const Action &getSource() const { return Source; } const char *getExecutable() const { return Executable; } + const ArgStringList &getArguments() const { return Arguments; } static bool classof(const Job *J) { |