Return an adjusted path such that non-empty instances do not have a trailing separator.
See Implementation
Return an adjusted path such that non-empty instances do not have a trailing separator.