[swift-evolution] [Pitch] Rename Mirror
Anton Zhilin
antonyzhilin at gmail.com
Thu Jul 21 18:49:20 CDT 2016
2016-07-22 2:39 GMT+03:00 Dmitri Gribenko <gribozavr at gmail.com>:
> On Thu, Jul 21, 2016 at 4:06 PM, Anton Zhilin <antonyzhilin at gmail.com>
> wrote:
> > Moreover, types can completely customize contents of their
> > 'Mirror's. This is incompatible with laziness and with how reflection
> should
> > work, based on experience from other languages.
>
> That is actually viewed as a weakness of reflection in other
> languages. Allowing reflection to access other types' internal data
> and APIs creates barriers for optimization, and facilitates creating
> binary compatibility problems when apps include code that uses
> reflection to poke at internal data of library types.
I talked about Swift here. Types can completely customize contents of their
Mirrors in Swift. A type, which pretends to be used for reflection, can't
afford that.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160722/a063de25/attachment.html>
More information about the swift-evolution
mailing list