mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Use abstract implicit-conversion expressions for bridging cases instead of
expanding the conversion calls in Sema.
This commit is contained in:
@@ -502,6 +502,9 @@ ConcreteDeclRef Expr::getReferencedDecl() const {
|
||||
PASS_THROUGH_REFERENCE(PointerToPointer, getSubExpr);
|
||||
PASS_THROUGH_REFERENCE(ForeignObjectConversion, getSubExpr);
|
||||
PASS_THROUGH_REFERENCE(UnevaluatedInstance, getSubExpr);
|
||||
PASS_THROUGH_REFERENCE(BridgeToObjC, getSubExpr);
|
||||
PASS_THROUGH_REFERENCE(BridgeFromObjC, getSubExpr);
|
||||
PASS_THROUGH_REFERENCE(ConditionalBridgeFromObjC, getSubExpr);
|
||||
NO_REFERENCE(Coerce);
|
||||
NO_REFERENCE(ForcedCheckedCast);
|
||||
NO_REFERENCE(ConditionalCheckedCast);
|
||||
@@ -789,6 +792,9 @@ bool Expr::canAppendPostfixExpression(bool appendingPostfixOperator) const {
|
||||
case ExprKind::ForeignObjectConversion:
|
||||
case ExprKind::UnevaluatedInstance:
|
||||
case ExprKind::EnumIsCase:
|
||||
case ExprKind::ConditionalBridgeFromObjC:
|
||||
case ExprKind::BridgeFromObjC:
|
||||
case ExprKind::BridgeToObjC:
|
||||
// Implicit conversion nodes have no syntax of their own; defer to the
|
||||
// subexpression.
|
||||
return cast<ImplicitConversionExpr>(this)->getSubExpr()
|
||||
|
||||
Reference in New Issue
Block a user