Files
swift-mirror/lib/Sema/CSSimplify.cpp
John McCall ef4fb36c50 Only permit checked downcasts of an existential to a subtype,
not to an arbitrary type that's convertible to the existential.
Arbitrary conversions aren't necessarily reversible.

The specific test case in rdar://16041990 involves a downcast
to String instead of NSString; that's supportable in principle,
but it's at the very least a significant feature, and clearly
there are non-reversible conversions out there.

Swift SVN r14028
2014-02-18 02:27:31 +00:00

72 KiB