Replace llvm::sys::Path with llvm::SmallString in gen_gccbuiltins.cpp.

This commit is contained in:
kai 2013-06-29 15:25:34 +02:00
parent 8fb0b12e9e
commit bb37ef656b

View file

@ -14,9 +14,10 @@
//===----------------------------------------------------------------------===// //===----------------------------------------------------------------------===//
#include "llvm/TableGen/Main.h" #include "llvm/TableGen/Main.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/StringRef.h" #include "llvm/ADT/StringRef.h"
#include "llvm/Support/CommandLine.h" #include "llvm/Support/CommandLine.h"
#include "llvm/Support/PathV1.h" #include "llvm/Support/Path.h"
#include "llvm/TableGen/Record.h" #include "llvm/TableGen/Record.h"
#if LDC_LLVM_VER < 302 #if LDC_LLVM_VER < 302
#include "llvm/TableGen/TableGenAction.h" #include "llvm/TableGen/TableGenAction.h"
@ -171,12 +172,12 @@ int main(int argc, char** argv)
return 1; return 1;
} }
sys::Path file(LLVM_INTRINSIC_TD_PATH); llvm::SmallString<128> file(LLVM_INTRINSIC_TD_PATH);
file.appendComponent("llvm"); sys::path::append(file, "llvm");
#if LDC_LLVM_VER >= 303 #if LDC_LLVM_VER >= 303
file.appendComponent("IR"); sys::path::append(file, "IR");
#endif #endif
file.appendComponent("Intrinsics.td"); sys::path::append(file, "Intrinsics.td");
string iStr = string("-I=") + string(LLVM_INTRINSIC_TD_PATH); string iStr = string("-I=") + string(LLVM_INTRINSIC_TD_PATH);
string oStr = string("-o=") + argv[1]; string oStr = string("-o=") + argv[1];