On Fri, 15 May 2026 07:52:25 GMT, Volkan Yazici <[email protected]> wrote:

>> Document and test empty path segment normalization in `java.net.URI`.
>> 
>> ---------
>> - [X] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Volkan Yazici has updated the pull request incrementally with two additional 
> commits since the last revision:
> 
>  - `empty path segments` -> `empty segments`
>  - `{@code "//"} segment` -> `empty segment`

src/java.base/share/classes/java/net/URI.java line 179:

> 177:  *
> 178:  * <p> <i>Normalization</i> is the process of removing unnecessary 
> {@code "."},
> 179:  * {@code ".."}, and {@code "//"} (empty) segments from the path 
> component of a

may I suggest:

Suggestion:

 * {@code ".."} segments, and redundant {@code "/"} (empty segments) from the 
path component of a


@AlanBateman would you agree?

src/java.base/share/classes/java/net/URI.java line 1033:

> 1031:      *   <b><i>(Deviation from RFC&nbsp;2396)</i></b> </p></li>
> 1032:      *
> 1033:      *   <li><p> All {@code "//"} empty segments are removed.

Suggestion:

     *   <li><p> All redundant {@code "/"} (empty segments) are removed.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/31150#discussion_r3247115585
PR Review Comment: https://git.openjdk.org/jdk/pull/31150#discussion_r3247111408

Reply via email to