[swift-evolution] [Pitch] Refactor Metatypes

Adrian Zubarev adrian.zubarev at devandartist.com
Fri Feb 17 10:09:31 CST 2017

Personally I’d like a shortcut like AnyType, but it won’t work as a typealias, because it will create a circle reference between AnyType and AnyType<T>.

However, there is a small possibility that this type might be generalized like Any (now possibly AnyObject) directly into the language. That would probably allow us to use AnyType as a shortcut to AnyType<Any>.

I’m not sure if this should be part of our proposal or not. I’d like to have some more feedback from the core team on this one.

Adrian Zubarev
Sent with Airmail

Am 17. Februar 2017 um 14:24:14, Anton Zhilin (antonyzhilin at gmail.com) schrieb:

I guess, now is the time? The response on this has been positive, both for the new metatype syntax and separation of static and dynamic metatypes.

I’ve got one more feature in mind since then—a shorthand of  
AnyType ≡  
Would this addition be worth extra syntax? Is it feasible from current generics point of view? Anyway, it can be done in a separate proposal.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20170217/fa277614/attachment.html>

More information about the swift-evolution mailing list