Customized header search paths
1. Use "-I <path>" (or "--include-path <path>") to add a header search path.
2. You can specify more than 1 search path and the preceding path takes precedence.
3. System include path is moved out of the code -- they are inserted in the build system instead.
Change-Id: Idfaee4763e8bf0cd71deeecdf1dc1ec515e44d0f
diff --git a/slang.hpp b/slang.hpp
index 551e405..fa6cfbd 100644
--- a/slang.hpp
+++ b/slang.hpp
@@ -9,6 +9,7 @@
#include <cstdio>
#include <string>
+#include <vector>
#include "llvm/Support/raw_ostream.h" /* for class llvm::raw_ostream */
@@ -150,6 +151,8 @@
bool mAllowRSPrefix;
+ std::vector<std::string> mIncludePaths;
+
public:
static const std::string TargetDescription;
@@ -161,6 +164,8 @@
bool setInputSource(llvm::StringRef inputFile);
+ void addIncludePath(const char* path);
+
void setOutputType(SlangCompilerOutputTy outputType);
inline bool setOutput(FILE* stream) {