@@ -280,7 +280,7 @@ DIT unwrapDI(LLVMMetadataRef ref) {
280
280
} \
281
281
}
282
282
283
- # if ENABLE_PNACL
283
+ # if PNACL_LLVM
284
284
// The NaCl SDK and Rust use slightly different LLVM 3.7 versions.
285
285
// In the small space between these two revisions, LLVM has managed to modify
286
286
// just about every DIBuilder function.
@@ -375,9 +375,9 @@ extern "C" LLVMMetadataRef LLVMDIBuilderCreateSubroutineType(
375
375
LLVMMetadataRef ParameterTypes) {
376
376
return wrap (Builder->createSubroutineType (
377
377
unwrapDI<DIFile>(File),
378
- #if LLVM_VERSION_MINOR >= 7 && !ENABLE_PNACL
378
+ #if LLVM_VERSION_MINOR >= 7 && !PNACL_LLVM
379
379
DITypeRefArray (unwrap<MDTuple>(ParameterTypes))));
380
- #elif LLVM_VERSION_MINOR >= 6 || ENABLE_PNACL
380
+ #elif LLVM_VERSION_MINOR >= 6 || PNACL_LLVM
381
381
unwrapDI<DITypeArray>(ParameterTypes)));
382
382
#else
383
383
unwrapDI<DIArray>(ParameterTypes)));
@@ -618,7 +618,7 @@ extern "C" LLVMValueRef LLVMDIBuilderInsertDeclareAtEnd(
618
618
LLVMBasicBlockRef InsertAtEnd) {
619
619
return wrap (Builder->insertDeclare (
620
620
unwrap (Val),
621
- #if LLVM_VERSION_MINOR >= 7 && !ENABLE_PNACL
621
+ #if LLVM_VERSION_MINOR >= 7 && !PNACL_LLVM
622
622
unwrap<DILocalVariable>(VarInfo),
623
623
#else
624
624
unwrapDI<DIVariable>(VarInfo),
@@ -645,7 +645,7 @@ extern "C" LLVMValueRef LLVMDIBuilderInsertDeclareBefore(
645
645
#endif
646
646
return wrap (Builder->insertDeclare (
647
647
unwrap (Val),
648
- #if LLVM_VERSION_MINOR >= 7 && !ENABLE_PNACL
648
+ #if LLVM_VERSION_MINOR >= 7 && !PNACL_LLVM
649
649
unwrap<DILocalVariable>(VarInfo),
650
650
#else
651
651
unwrapDI<DIVariable>(VarInfo),
@@ -836,7 +836,7 @@ LLVMRustLinkInExternalBitcode(LLVMModuleRef dst, char *bc, size_t len) {
836
836
Module *Dst = unwrap (dst);
837
837
#if LLVM_VERSION_MINOR >= 6
838
838
std::unique_ptr<MemoryBuffer> buf = MemoryBuffer::getMemBufferCopy (StringRef (bc, len));
839
- #if LLVM_VERSION_MINOR >= 7 && !ENABLE_PNACL
839
+ #if LLVM_VERSION_MINOR >= 7 && !PNACL_LLVM
840
840
ErrorOr<std::unique_ptr<Module>> Src =
841
841
llvm::getLazyBitcodeModule (std::move (buf), Dst->getContext ());
842
842
#else
@@ -863,7 +863,7 @@ LLVMRustLinkInExternalBitcode(LLVMModuleRef dst, char *bc, size_t len) {
863
863
#if LLVM_VERSION_MINOR >= 6
864
864
raw_string_ostream Stream (Err);
865
865
DiagnosticPrinterRawOStream DP (Stream);
866
- #if LLVM_VERSION_MINOR >= 7 && !ENABLE_PNACL
866
+ #if LLVM_VERSION_MINOR >= 7 && !PNACL_LLVM
867
867
if (Linker::LinkModules (Dst, Src->get (), [&](const DiagnosticInfo &DI) { DI.print (DP); })) {
868
868
#else
869
869
if (Linker::LinkModules (Dst, *Src, [&](const DiagnosticInfo &DI) { DI.print (DP); })) {
@@ -1002,7 +1002,7 @@ LLVMRustBuildLandingPad(LLVMBuilderRef Builder,
1002
1002
unsigned NumClauses,
1003
1003
const char * Name,
1004
1004
LLVMValueRef F) {
1005
- #if LLVM_VERSION_MINOR >= 7 && !ENABLE_PNACL
1005
+ #if LLVM_VERSION_MINOR >= 7 && !PNACL_LLVM
1006
1006
unwrap<Function>(F)->setPersonalityFn (unwrap<Constant>(PersFn));
1007
1007
return LLVMBuildLandingPad (Builder, Ty, NumClauses, Name);
1008
1008
#else
0 commit comments