@swift-5.10.1@swift-6.0.3import Foundation let a = URL(fileURLWithPath: "common.ts") let dir = a.deletingLastPathComponent() let dirA = dir.appendingPathComponent(a.relativePath) print("dirA abs='\(dirA.path)'") print("dirA rel='\(dirA.relativePath)'")