Re: RFR: 8274835: Remove unnecessary castings in java.base

2021-10-29 Thread Tagir Valeev
On Thu, Oct 7, 2021 at 12:15 AM Joe Darcy wrote: > Curious. The JDK build is done with javac -Xlint:cast warning enabled > (JDK-8032734) which is intended to catch issues like this. Perhaps IntelliJ > is using a different (or sharper) analysis. Yes, our analysis is written independently of Jav

Re: RFR: 8274835: Remove unnecessary castings in java.base

2021-10-06 Thread Brian Burkhalter
On Thu, 9 Sep 2021 20:12:47 GMT, Andrey Turbanov wrote: > Redundant castings make code harder to read. > Found them by IntelliJ IDEA. > I tried to select only casts which are definitely safe to remove. Also didn't > touch primitive types casts. `java.io` change looks all right. -

Re: RFR: 8274835: Remove unnecessary castings in java.base

2021-10-06 Thread Joe Darcy
On Thu, 9 Sep 2021 20:12:47 GMT, Andrey Turbanov wrote: > Redundant castings make code harder to read. > Found them by IntelliJ IDEA. > I tried to select only casts which are definitely safe to remove. Also didn't > touch primitive types casts. Curious. The JDK build is done with javac -Xlint:

Re: RFR: 8274835: Remove unnecessary castings in java.base

2021-10-06 Thread Lance Andersen
On Thu, 9 Sep 2021 20:12:47 GMT, Andrey Turbanov wrote: > Redundant castings make code harder to read. > Found them by IntelliJ IDEA. > I tried to select only casts which are definitely safe to remove. Also didn't > touch primitive types casts. Marked as reviewed by lancea (Reviewer). ---

Re: RFR: 8274835: Remove unnecessary castings in java.base

2021-10-06 Thread Naoto Sato
On Thu, 9 Sep 2021 20:12:47 GMT, Andrey Turbanov wrote: > Redundant castings make code harder to read. > Found them by IntelliJ IDEA. > I tried to select only casts which are definitely safe to remove. Also didn't > touch primitive types casts. Calendar-related changes look good to me. --

Re: RFR: 8274835: Remove unnecessary castings in java.base

2021-10-06 Thread Sean Mullan
On Thu, 9 Sep 2021 20:12:47 GMT, Andrey Turbanov wrote: > Redundant castings make code harder to read. > Found them by IntelliJ IDEA. > I tried to select only casts which are definitely safe to remove. Also didn't > touch primitive types casts. The security related files look fine. --