llvm::Value *null = llvm::Constant::getNullValue(CGF.ConvertType(type));
// Note that the following is not equivalent to
// EmitStoreThroughBitfieldLValue for ARC types.
- if (lv.isBitField())
+ if (lv.isBitField()) {
CGF.EmitStoreThroughBitfieldLValue(RValue::get(null), lv);
- assert(lv.isSimple());
- CGF.EmitStoreOfScalar(null, lv, /* isInitialization */ true);
+ } else {
+ assert(lv.isSimple());
+ CGF.EmitStoreOfScalar(null, lv, /* isInitialization */ true);
+ }
} else {
// There's a potential optimization opportunity in combining
// memsets; that would be easy for arrays, but relatively
struct test12 (*p)(void);
} test12g;
+
+void test13(int x) {
+ struct X { int a; int b : 10; int c; };
+ struct X y = {.c = x};
+ // CHECK: @test13
+ // CHECK: and i32 {{.*}}, -1024
+}