File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -2440,13 +2440,17 @@ bool ByteCodeExprGen<Emitter>::VisitCXXUuidofExpr(const CXXUuidofExpr *E) {
2440
2440
template <class Emitter >
2441
2441
bool ByteCodeExprGen<Emitter>::VisitRequiresExpr(const RequiresExpr *E) {
2442
2442
assert (classifyPrim (E->getType ()) == PT_Bool);
2443
+ if (DiscardResult)
2444
+ return true ;
2443
2445
return this ->emitConstBool (E->isSatisfied (), E);
2444
2446
}
2445
2447
2446
2448
template <class Emitter >
2447
2449
bool ByteCodeExprGen<Emitter>::VisitConceptSpecializationExpr(
2448
2450
const ConceptSpecializationExpr *E) {
2449
2451
assert (classifyPrim (E->getType ()) == PT_Bool);
2452
+ if (DiscardResult)
2453
+ return true ;
2450
2454
return this ->emitConstBool (E->isSatisfied (), E);
2451
2455
}
2452
2456
Original file line number Diff line number Diff line change @@ -985,6 +985,8 @@ namespace DiscardExprs {
985
985
__uuidof (GuidType);
986
986
__uuidof (number); // both-error {{cannot call operator __uuidof on a type with no GUID}}
987
987
988
+ requires {false ;};
989
+
988
990
return 0 ;
989
991
}
990
992
static_assert (ignoredExprs() == 0 , " " );
You can’t perform that action at this time.
0 commit comments