Skip to content

variances-page: use T and S instead of A and B #723

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 13, 2017

Conversation

Philippus
Copy link
Member

like in the description and some styling fixes

mentioned in the comments of http://docs.scala-lang.org/tutorials/tour/variances.html

@SethTisue SethTisue merged commit 919471a into scala:master Mar 13, 2017
@SethTisue
Copy link
Member

someone was telling me recently that A and B are more idiomatic in Scala, and perhaps we should try to be consistent on this tour-wide. but regardless, this is an improvement. thank you!

@som-snytt
Copy link
Contributor

I also learned early to use A and B and find anything else jarring except CC in collections, or maybe Elem.

I haven't heard why that's idiomatic but not f(x, y, z). With named and partial application of type params, the mores would change.

What the neutral A expresses is, as a List[A], I don't care what I'm a list of. But if I'm a Map[A, B], I might prefer Map[K, V] or similar.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants