(to flesh out)
Ref:
@adriaanm is this something we need to make sure happens for RC1?
I think we can figure this (and any other deprecation strategy) out early in the 2.13.x cycle.
I would just like to point out that once you have HList-like tuples in Scala 3, having auto-tupling only for arguments which have a Tuple upper bound is a pretty great way to have syntax-free arity abstraction. It seems a bit strange to on the one hand build arity abstraction into the language and std library, and on the other remove a feature that could make arity abstraction great, which was available when arity abstraction was hard to do anyway.
I don't think it could still cause confusion or weird runtime errors either, since auto-tupling will only happen when a tuple is already expected.
The reason that right now not much breaks between removing auto-tupling for Any or Unit bounded arguments, and removing it for everything, is probably that
Product which all case classes have, anddef foo(a: (Int, Int)) or def foo[A <: (Int, Int)](a: A), cause right now it's used exactly the same as def foo(a: Int, b: Int) except it has a bunch of extra overhead.Without auto-tupling I think I would actually prefer (syntax-wise) shapeless hlists over built-in tuples-as-hlists. To me foo((1, 2, 3)) looks worse/weirder/uglier than foo(1 :: 2 :: 3 :: HNil).
new plan at https://github.com/lampepfl/dotty/pull/4311#issuecomment-435593905
Most helpful comment
I would just like to point out that once you have HList-like tuples in Scala 3, having auto-tupling only for arguments which have a
Tupleupper bound is a pretty great way to have syntax-free arity abstraction. It seems a bit strange to on the one hand build arity abstraction into the language and std library, and on the other remove a feature that could make arity abstraction great, which was available when arity abstraction was hard to do anyway.I don't think it could still cause confusion or weird runtime errors either, since auto-tupling will only happen when a tuple is already expected.
The reason that right now not much breaks between removing auto-tupling for
AnyorUnitbounded arguments, and removing it for everything, is probably thatProductwhich all case classes have, anddef foo(a: (Int, Int))ordef foo[A <: (Int, Int)](a: A), cause right now it's used exactly the same asdef foo(a: Int, b: Int)except it has a bunch of extra overhead.Without auto-tupling I think I would actually prefer (syntax-wise) shapeless hlists over built-in tuples-as-hlists. To me
foo((1, 2, 3))looks worse/weirder/uglier thanfoo(1 :: 2 :: 3 :: HNil).