Note that the current proposal in Scala 3 is to make this work as I expected. If you wanted the old Scala 2 behavior, you would have to write,
List(1, 2, 3).to[Vector].explicitly(1)
I'm fine with that as a solution, but @li_haoyi's proposal (in the GitHub thread) goes further.
-
-
Show this thread
-
"the old behavior" = "the same confusing compile error" in this particular case. I should have picked a better example. ;)
Show this thread
End of conversation
New conversation -
-
-
This Tweet is unavailable.
-
There's probably a CanBuildFrom in there.
- Show replies
-
-
-
Implicit parameters are special and declaring those arguments and passing them should have always had a separate syntax. I like
@odersky's ?() and@Blaisorblade's [[]] proposals.Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.