Closed
Description
- Version: tested with v7.7.4 and v9.2.0
- Platform: Windows 10 (64-bit)
- Subsystem: path
Code says it best:
> path.relative('c:', 'c:\\test')
'..\\..\\test'
> path.relative('c:', 'c:/test')
'..\\..\\test'
Not sure why c: is treated differently here, but for all other volumes it returns the right result:
> path.relative('d:', 'd:\\test')
'test'
> path.relative('d:', 'd:/test')
'test'
also it appears to happen only on the root level:
> path.relative('c:\\test', 'c:\\test\\sub')
'sub'
and only if the colon is the last character of the base path
> path.relative('c:\\', 'c:\\test')
'test'