Fix builds with LLVM < 3.6
This commit is contained in:
parent
1d12b6d444
commit
f1f67b2848
1 changed files with 8 additions and 0 deletions
|
@ -282,7 +282,11 @@ extern "C" LLVMValueRef LLVMDIBuilderCreateSubroutineType(
|
||||||
LLVMValueRef ParameterTypes) {
|
LLVMValueRef ParameterTypes) {
|
||||||
return wrap(Builder->createSubroutineType(
|
return wrap(Builder->createSubroutineType(
|
||||||
unwrapDI<DIFile>(File),
|
unwrapDI<DIFile>(File),
|
||||||
|
#if LLVM_VERSION_MINOR >= 6
|
||||||
unwrapDI<DITypeArray>(ParameterTypes)));
|
unwrapDI<DITypeArray>(ParameterTypes)));
|
||||||
|
#else
|
||||||
|
unwrapDI<DIArray>(ParameterTypes)));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C" LLVMValueRef LLVMDIBuilderCreateFunction(
|
extern "C" LLVMValueRef LLVMDIBuilderCreateFunction(
|
||||||
|
@ -634,7 +638,11 @@ extern "C" void LLVMDICompositeTypeSetTypeArray(
|
||||||
LLVMValueRef CompositeType,
|
LLVMValueRef CompositeType,
|
||||||
LLVMValueRef TypeArray)
|
LLVMValueRef TypeArray)
|
||||||
{
|
{
|
||||||
|
#if LLVM_VERSION_MINOR >= 6
|
||||||
unwrapDI<DICompositeType>(CompositeType).setArrays(unwrapDI<DIArray>(TypeArray));
|
unwrapDI<DICompositeType>(CompositeType).setArrays(unwrapDI<DIArray>(TypeArray));
|
||||||
|
#else
|
||||||
|
unwrapDI<DICompositeType>(CompositeType).setTypeArray(unwrapDI<DIArray>(TypeArray));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C" char *LLVMTypeToString(LLVMTypeRef Type) {
|
extern "C" char *LLVMTypeToString(LLVMTypeRef Type) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue