RFR: 8374342: Remove incorrect @throws NoSuchFileException from FileUtils.java
eunbin son
duke at openjdk.org
Thu Dec 25 01:13:18 UTC 2025
### Summary
Remove incorrect @throws documentation from FileUtils.deleteFileIfExistsWithRetry.
### Description
The method documentation states that no exception is thrown if the file does not exist.
The implementation checks file existence before deletion and does not throw NoSuchFileException in this case.
This change removes the contradictory @throws clause.
No behavior is changed.
### Bug ID : JDK-8374342
https://bugs.java.com/bugdatabase/view_bug?bug_id=8374342
-------------
Commit messages:
- 8374342: Remove incorrect @throws NoSuchFileException from FileUtils.java
Changes: https://git.openjdk.org/jdk/pull/28985/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=28985&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8374342
Stats: 2 lines in 1 file changed: 0 ins; 2 del; 0 mod
Patch: https://git.openjdk.org/jdk/pull/28985.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/28985/head:pull/28985
PR: https://git.openjdk.org/jdk/pull/28985
More information about the core-libs-dev
mailing list