1 //===--- Job.cpp - Command to Execute -----------------------------------*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #include "clang/Driver/Job.h"
13 using namespace clang::driver;
17 Command::Command(const char *_Executable, const ArgStringList &_Arguments)
18 : Job(CommandClass), Executable(_Executable), Arguments(_Arguments) {
21 PipedJob::PipedJob() : Job(PipedJobClass) {}
23 JobList::JobList() : Job(JobListClass) {}
25 void Job::addCommand(Command *C) {
26 if (PipedJob *PJ = dyn_cast<PipedJob>(this))
29 cast<JobList>(this)->addJob(C);