[cfe-commits] r66978 - in /cfe/trunk: include/clang/Driver/Action.h lib/Driver/Action.cpp
Daniel Dunbar
daniel at zuster.org
Fri Mar 13 16:08:04 PDT 2009
Author: ddunbar
Date: Fri Mar 13 18:08:03 2009
New Revision: 66978
URL: http://llvm.org/viewvc/llvm-project?rev=66978&view=rev
Log:
Driver: Provide food and shelter for Action vtables.
Modified:
cfe/trunk/include/clang/Driver/Action.h
cfe/trunk/lib/Driver/Action.cpp
Modified: cfe/trunk/include/clang/Driver/Action.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Driver/Action.h?rev=66978&r1=66977&r2=66978&view=diff
==============================================================================
--- cfe/trunk/include/clang/Driver/Action.h (original)
+++ cfe/trunk/include/clang/Driver/Action.h Fri Mar 13 18:08:03 2009
@@ -84,8 +84,7 @@
class InputAction : public Action {
const Arg &Input;
public:
- InputAction(const Arg &_Input, types::ID _Type) : Action(InputClass, _Type),
- Input(_Input) {}
+ InputAction(const Arg &_Input, types::ID _Type);
const Arg &getInputArg() const { return Input; }
@@ -99,9 +98,7 @@
const char *ArchName;
public:
- BindArchAction(Action *Input, const char *_ArchName)
- : Action(BindArchClass, Input, Input->getType()), ArchName(_ArchName) {
- }
+ BindArchAction(Action *Input, const char *_ArchName);
const char *getArchName() const { return ArchName; }
@@ -113,10 +110,8 @@
class JobAction : public Action {
protected:
- JobAction(ActionClass Kind, Action *Input, types::ID Type)
- : Action(Kind, Input, Type) {}
- JobAction(ActionClass Kind, const ActionList &Inputs, types::ID Type)
- : Action(Kind, Inputs, Type) {}
+ JobAction(ActionClass Kind, Action *Input, types::ID Type);
+ JobAction(ActionClass Kind, const ActionList &Inputs, types::ID Type);
public:
static bool classof(const Action *A) {
@@ -128,9 +123,7 @@
class PreprocessJobAction : public JobAction {
public:
- PreprocessJobAction(Action *Input, types::ID OutputType)
- : JobAction(PreprocessJobClass, Input, OutputType) {
- }
+ PreprocessJobAction(Action *Input, types::ID OutputType);
static bool classof(const Action *A) {
return A->getKind() == PreprocessJobClass;
@@ -140,9 +133,7 @@
class PrecompileJobAction : public JobAction {
public:
- PrecompileJobAction(Action *Input, types::ID OutputType)
- : JobAction(PrecompileJobClass, Input, OutputType) {
- }
+ PrecompileJobAction(Action *Input, types::ID OutputType);
static bool classof(const Action *A) {
return A->getKind() == PrecompileJobClass;
@@ -152,9 +143,7 @@
class AnalyzeJobAction : public JobAction {
public:
- AnalyzeJobAction(Action *Input, types::ID OutputType)
- : JobAction(AnalyzeJobClass, Input, OutputType) {
- }
+ AnalyzeJobAction(Action *Input, types::ID OutputType);
static bool classof(const Action *A) {
return A->getKind() == AnalyzeJobClass;
@@ -164,9 +153,7 @@
class CompileJobAction : public JobAction {
public:
- CompileJobAction(Action *Input, types::ID OutputType)
- : JobAction(CompileJobClass, Input, OutputType) {
- }
+ CompileJobAction(Action *Input, types::ID OutputType);
static bool classof(const Action *A) {
return A->getKind() == CompileJobClass;
@@ -176,9 +163,7 @@
class AssembleJobAction : public JobAction {
public:
- AssembleJobAction(Action *Input, types::ID OutputType)
- : JobAction(AssembleJobClass, Input, OutputType) {
- }
+ AssembleJobAction(Action *Input, types::ID OutputType);
static bool classof(const Action *A) {
return A->getKind() == AssembleJobClass;
@@ -188,8 +173,7 @@
class LinkJobAction : public JobAction {
public:
- LinkJobAction(ActionList &Inputs, types::ID Type)
- : JobAction(LinkJobClass, Inputs, Type) {}
+ LinkJobAction(ActionList &Inputs, types::ID Type);
static bool classof(const Action *A) {
return A->getKind() == LinkJobClass;
@@ -199,8 +183,7 @@
class LipoJobAction : public JobAction {
public:
- LipoJobAction(ActionList &Inputs, types::ID Type)
- : JobAction(LipoJobClass, Inputs, Type) {}
+ LipoJobAction(ActionList &Inputs, types::ID Type);
static bool classof(const Action *A) {
return A->getKind() == LipoJobClass;
Modified: cfe/trunk/lib/Driver/Action.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Action.cpp?rev=66978&r1=66977&r2=66978&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/Action.cpp (original)
+++ cfe/trunk/lib/Driver/Action.cpp Fri Mar 13 18:08:03 2009
@@ -30,3 +30,47 @@
assert(0 && "invalid class");
return 0;
}
+
+InputAction::InputAction(const Arg &_Input, types::ID _Type)
+ : Action(InputClass, _Type), Input(_Input) {
+}
+
+BindArchAction::BindArchAction(Action *Input, const char *_ArchName)
+ : Action(BindArchClass, Input, Input->getType()), ArchName(_ArchName) {
+}
+
+JobAction::JobAction(ActionClass Kind, Action *Input, types::ID Type)
+ : Action(Kind, Input, Type) {
+}
+
+JobAction::JobAction(ActionClass Kind, const ActionList &Inputs, types::ID Type)
+ : Action(Kind, Inputs, Type) {
+}
+
+PreprocessJobAction::PreprocessJobAction(Action *Input, types::ID OutputType)
+ : JobAction(PreprocessJobClass, Input, OutputType) {
+}
+
+PrecompileJobAction::PrecompileJobAction(Action *Input, types::ID OutputType)
+ : JobAction(PrecompileJobClass, Input, OutputType) {
+}
+
+AnalyzeJobAction::AnalyzeJobAction(Action *Input, types::ID OutputType)
+ : JobAction(AnalyzeJobClass, Input, OutputType) {
+}
+
+CompileJobAction::CompileJobAction(Action *Input, types::ID OutputType)
+ : JobAction(CompileJobClass, Input, OutputType) {
+}
+
+AssembleJobAction::AssembleJobAction(Action *Input, types::ID OutputType)
+ : JobAction(AssembleJobClass, Input, OutputType) {
+}
+
+LinkJobAction::LinkJobAction(ActionList &Inputs, types::ID Type)
+ : JobAction(LinkJobClass, Inputs, Type) {
+}
+
+LipoJobAction(ActionList &Inputs, types::ID Type)
+ : JobAction(LipoJobClass, Inputs, Type) {
+}
More information about the cfe-commits
mailing list