[swift-evolution] Specified Protocol Conformances in Subclasses

Anton Zhilin antonyzhilin at gmail.com
Fri Mar 10 06:33:17 CST 2017


Looks like a compiler bug, since it works with classes:

class Base {}class Derived : Base {}
class A {
    var x: Base? { return Base() }
}
class B : A {
    override var x: Derived? { return Derived() }
}

‚Äč
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20170310/af3ccac2/attachment.html>


More information about the swift-evolution mailing list