Avatar
Avatar
Iceman
@swift-5.6.3 @swift-5.7.3 extension Substring { /// Converts all `\"` to `"`. func unescapingDoubleQuotes() -> Substring { self.lazy.split(separator: "\\").reduce(into: "") { (result, part) in if result.isEmpty || part.first == "\"" { result += part } else { result += "\\" + part } } } }
no output