[swift-dev] Emitting redundant protocol conformances to support type lookup

Luke Howard lukeh at padl.com
Tue Jan 12 21:46:50 CST 2016


Would it be possible to extend GenericParameterDescriptor to include a tail-emplaced set of references to ProtocolDescriptors for any parameter type constraints that require witness tables? This would be useful plumbing for a future API that can dynamically instantiate generic types.

See:

https://github.com/lhoward/swift/blob/SR-381/include/swift/Runtime/Metadata.h#L1199 <https://github.com/lhoward/swift/blob/SR-381/include/swift/Runtime/Metadata.h#L1199>

https://github.com/lhoward/swift/blob/SR-381/stdlib/public/runtime/MetadataLookup.cpp#L338 <https://github.com/lhoward/swift/blob/SR-381/stdlib/public/runtime/MetadataLookup.cpp#L338>

— Luke
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-dev/attachments/20160113/d0ef3552/attachment.html>


More information about the swift-dev mailing list