From db3b9a4992c672d53070a1c8ddb4458a8696b057 Mon Sep 17 00:00:00 2001 From: Graydon Hoare Date: Sat, 7 May 2011 18:54:23 +0000 Subject: Stop stringifying integers to get integral constants. --- src/rustllvm/RustWrapper.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/rustllvm/RustWrapper.cpp') diff --git a/src/rustllvm/RustWrapper.cpp b/src/rustllvm/RustWrapper.cpp index b1705f10ae3..b57695199f9 100644 --- a/src/rustllvm/RustWrapper.cpp +++ b/src/rustllvm/RustWrapper.cpp @@ -116,3 +116,8 @@ extern "C" const char *LLVMRustGetHostTriple(void) static std::string str = llvm::sys::getHostTriple(); return str.c_str(); } + +extern "C" LLVMValueRef LLVMRustConstSmallInt(LLVMTypeRef IntTy, unsigned N, + LLVMBool SignExtend) { + return LLVMConstInt(IntTy, (unsigned long long)N, SignExtend); +} -- cgit 1.4.1-3-g733a5