On Mon, 6 Jun 2022 21:27:25 GMT, Jonathan Gibbons <j...@openjdk.org> wrote:
>> Pavel Rappo has updated the pull request incrementally with three additional >> commits since the last revision: >> >> - Remove upper-bounded wildcard >> >> This change simplifies code without any disadvantages: >> >> * Those `List<? extends XTree>` are read-only >> * An argument of the `List<XTree>` type can still be passed to a >> `List<? extends XTree>` parameter >> - Simplify inheritThrowsDocumentation >> - Reuse more specific variable > > src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/taglets/ParamTaglet.java > line 92: > >> 90: ? utils.getTypeParamTrees(ee) >> 91: : utils.getParamTrees(ee); >> 92: List<? extends Element> parameters = input.isTypeVariableParamTag > > Change both or neither; don't leave the code inconsistent I'm not sure why list of parameter trees have to be the same as list of elements. I can change (methods such as) `Utils#getTypeParamTrees`, but I cannot change (methods such as) `ExecutableElement#getTypeParameters` (sadly). Useless bounded wildcards clutter code. ------------- PR: https://git.openjdk.java.net/jdk/pull/8886