File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -469,9 +469,11 @@ TEST(ConstantsTest, BuildConstantDataVectors) {
469
469
}
470
470
}
471
471
472
- TEST (ConstantsTest, BitcastToGEP ) {
472
+ void bitcastToGEPHelper ( bool useOpaquePointers ) {
473
473
LLVMContext Context;
474
474
std::unique_ptr<Module> M (new Module (" MyModule" , Context));
475
+ if (useOpaquePointers)
476
+ Context.enableOpaquePointers ();
475
477
476
478
auto *i32 = Type::getInt32Ty (Context);
477
479
auto *U = StructType::create (Context, " Unsized" );
@@ -490,6 +492,11 @@ TEST(ConstantsTest, BitcastToGEP) {
490
492
}
491
493
}
492
494
495
+ TEST (ConstantsTest, BitcastToGEP) {
496
+ bitcastToGEPHelper (true );
497
+ bitcastToGEPHelper (false );
498
+ }
499
+
493
500
bool foldFuncPtrAndConstToNull (LLVMContext &Context, Module *TheModule,
494
501
uint64_t AndValue,
495
502
MaybeAlign FunctionAlign = llvm::None) {
You can’t perform that action at this time.
0 commit comments