Add util.splitpath() and use it instead of using os.sep directly.
This change is intended to allow hooking splitpath() by win32mbcs
extension for MBCS support.
Add endswithsep() and use it instead of using os.sep and os.altsep directly.
This change is intended to allow hooking endswithsep() by win32mbcs
extension for MBCS support.