You said your issue only existed in Swift 3. However, you issue still
exists in Xcode 7.3.1, which uses Swift 2.2. I tested your playground code.
protocol QueryRow {
var key: Any { get }
func key(at index: UInt) -> Any?
}
var row: QueryRow
row.key as? String
Zhaoxin
On Wed, Sep 14, 2016 at 7:08 AM, Jens Alfke via swift-users <
[email protected]> wrote:
>
> On Sep 13, 2016, at 3:13 PM, Hooman Mehr <[email protected]> wrote:
>
> I guess the reason this is happening is some attempt at backward
> compatibility, but this is clearly causing a serious bug. Have you reported
> it?
>
>
> No; I’m not a Swift expert, and am not following the 3.0 transition
> closely enough to tell whether this is a bug or just some unfortunate but
> intentional fallout from the transition.
>
> —Jens
>
> _______________________________________________
> swift-users mailing list
> [email protected]
> https://lists.swift.org/mailman/listinfo/swift-users
>
>
_______________________________________________
swift-users mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-users