File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -1012,7 +1012,8 @@ mlir::Value CIRGenFunction::evaluateExprAsBool(const Expr *E) {
10121012
10131013LValue CIRGenFunction::buildUnaryOpLValue (const UnaryOperator *E) {
10141014 // __extension__ doesn't affect lvalue-ness.
1015- assert (E->getOpcode () != UO_Extension && " not implemented" );
1015+ if (E->getOpcode () == UO_Extension)
1016+ return buildLValue (E->getSubExpr ());
10161017
10171018 switch (E->getOpcode ()) {
10181019 default :
Original file line number Diff line number Diff line change @@ -9,3 +9,11 @@ int foo(void) { return __extension__ 0b101010; }
99//CHECK-NEXT: cir.store [[VAL]], [[ADDR]] : !s32i, cir.ptr <!s32i>
1010//CHECK-NEXT: [[LOAD_VAL:%.*]] = cir.load [[ADDR]] : cir.ptr <!s32i>, !s32i
1111//CHECK-NEXT: cir.return [[LOAD_VAL]] : !s32i
12+
13+ void bar (void ) {
14+ __extension__ bar ;
15+ }
16+
17+ //CHECK: cir.func @bar()
18+ //CHECK: {{.*}} = cir.get_global @bar : cir.ptr <!cir.func<!void ()>>
19+ //CHECK: cir.return
You can’t perform that action at this time.
0 commit comments