summaryrefslogtreecommitdiff
path: root/include/llvm/CompilerDriver/Tool.h
diff options
context:
space:
mode:
authorRoman Divacky <rdivacky@FreeBSD.org>2010-03-03 17:27:15 +0000
committerRoman Divacky <rdivacky@FreeBSD.org>2010-03-03 17:27:15 +0000
commit67a71b3184ce20a901e874d0ee25e01397dd87ef (patch)
tree836a05cff50ca46176117b86029f061fa4db54f0 /include/llvm/CompilerDriver/Tool.h
parent6fe5c7aa327e188b7176daa5595bbf075a6b94df (diff)
Notes
Diffstat (limited to 'include/llvm/CompilerDriver/Tool.h')
-rw-r--r--include/llvm/CompilerDriver/Tool.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/include/llvm/CompilerDriver/Tool.h b/include/llvm/CompilerDriver/Tool.h
index a982e2d397e7..85d1690bcfed 100644
--- a/include/llvm/CompilerDriver/Tool.h
+++ b/include/llvm/CompilerDriver/Tool.h
@@ -20,15 +20,19 @@
#include "llvm/ADT/StringSet.h"
#include "llvm/System/Path.h"
+#include <string>
#include <vector>
+#include <utility>
namespace llvmc {
class LanguageMap;
+ typedef std::vector<std::pair<unsigned, std::string> > ArgsVector;
typedef std::vector<llvm::sys::Path> PathVector;
+ typedef std::vector<std::string> StrVector;
typedef llvm::StringSet<> InputLanguagesSet;
- /// Tool - A class
+ /// Tool - Represents a single tool.
class Tool : public llvm::RefCountedBaseVPTR<Tool> {
public:
@@ -51,6 +55,7 @@ namespace llvmc {
virtual const char* OutputLanguage() const = 0;
virtual bool IsJoin() const = 0;
+ virtual bool WorksOnEmpty() const = 0;
protected:
/// OutFileName - Generate the output file name.
@@ -58,6 +63,8 @@ namespace llvmc {
const llvm::sys::Path& TempDir,
bool StopCompilation,
const char* OutputSuffix) const;
+
+ StrVector SortArgs(ArgsVector& Args) const;
};
/// JoinTool - A Tool that has an associated input file list.