splitPath: Do not rely on basename
Fix splitPath on Windows.
Currently splitPath ignores the drive letter. For example, splitPath("C:\\images\\my-image.svg") returns {"\\", "images", "my-image.svg"}. See commit message for details.
Fixes #5311 (closed)