Since the core team has already said that protocols such as Equatable
and Hashable
are coming to tuples, effectively that means that methods are coming to tuples.
If tuple conformance is meant to be a public feature (i.e. not only for stdlib protocols), I would expect that the following proposals would also be accepted:
- Extensions and protocol conformances for fixed-length, non-generic tuples, like
(Int, String)
. - Parameterized extensions, to extend this to fixed-length, generic tuples.
Perhaps it would be a good idea to start with those. The latter already has an implementation, but is there anything that would make the former very difficult for a community member to implement?
I agree (that it is the critical question of this thread).
What would be the size/scope of the changes needed for a barebones, stdlib-only version of variadic generics? (so we can bypass discussions about syntax or complete feature-set, and focus on the minimum required to implement these few conformances)