Code review request: JDK-8008670 (partial java.util.stream implementation)
brian.goetz at oracle.com
Mon Mar 11 19:12:38 PDT 2013
> 2) I find X_IN and X_OUT type parameters to be disruptive to reading.
> Sticking to a simple "I" and "O" would be much easier to read.
I'll answer this one because we've gotten it from a few places.
This is a nice idea, and it works fine up to a certain level of
complexity. But when you have a generic method of a generic class that
between them have five type variables, the single-letter scheme hits the
wall, and it crashes and burns. (This isn't supposition; the earlier
versions of this code base stuck to the single letter scheme and people
told us they couldn't keep track of which type variables are which. For
example, in the interaction between AbstractPipeline and PipelineHelper,
both have in and out parameters, and they're not the same, so I and O
are completely confusing in that context.) But one also wants to be
consistent. So when you cross the multi-letter boundary, you likely
have to stay there even in many cases where one letter would do.
More information about the lambda-dev