it seems the code snippit below cann't be compiled throuth.
the compiler complains:
error: no matching function for call to ‘llvm::IntegerType::get(int)’
/usr/local/include/llvm/DerivedTypes.h:108:
note: candidates are: static const llvm::IntegerType* llvm::IntegerType::get(llvm::LLVMContext&, unsigned int)
Module* makeLLVMModule() {
// Module Construction
Module* mod = new Module("test", getGlobalContext());
Constant* c = mod->getOrInsertFunction("mul_add",
/*ret type*/ IntegerType::get(32),
/*args*/ IntegerType::get(32),
IntegerType::get(32),
IntegerType::get(32),
/*varargs terminated with null*/ NULL);
Function* mul_add = cast<Function>(c);
mul_add->setCallingConv(CallingConv::C);
Hi 王建东,
it seems the code snippit below cann't be compiled throuth.
the compiler complains:
error: no matching function for call to ‘llvm::IntegerType::get(int)’
/usr/local/include/llvm/DerivedTypes.h:108:
is this the version of the tutorial released with llvm-2.7?
Ciao,
Duncan.