Did I mention that I hate java.nio.filePath. It must be one of the most stupid APIs in the JDK.
Why? Just check anything around the "empty" Path.
- The empty Path is defined in the docs but there is no .isEmpty() test.
- The empty Path has a size of 1
- The root path '/' has size of 0
- The parent of "x" is not the empty path but null
- Path.of("").resolveSibling("a") which cannot be correct by any definition
- subpath(0, 0) throws instead of returning the empty Path
😠😡