RFR: 8265426: Update java.security to use instanceof pattern variable

Weijun Wang weijun at openjdk.java.net
Mon Apr 26 23:27:36 UTC 2021


On Mon, 26 Apr 2021 08:50:36 GMT, Patrick Concannon <pconcannon at openjdk.org> wrote:

> Hi,
> 
> Could someone please review my code for updating the code in the `java.security` package to make use of the `instanceof` pattern variable?
> 
> Kind regards,
> Patrick

Two comments:

1. Why not reuse the existing variable name (Ex: `t` in `Type t = (Type)obj`) as much as possible to avoid unnecessary renames?
2. I'm not sure if modifying argument name in a public API is a good idea. This leads to unnecessary javadoc changes.

-------------

PR: https://git.openjdk.java.net/jdk/pull/3687



More information about the security-dev mailing list