diff --git a/Source/SourceKittenFramework/StringView.swift b/Source/SourceKittenFramework/StringView.swift index 7c3dce22..d597a5a9 100644 --- a/Source/SourceKittenFramework/StringView.swift +++ b/Source/SourceKittenFramework/StringView.swift @@ -145,13 +145,6 @@ public struct StringView { return byteRangeToNSRange(byteRange).map(nsString.substring) } - /// Returns a substring, started at UTF-16 location. - /// - /// - parameter location: UTF-16 location. - func substring(from location: Int) -> String { - return nsString.substring(from: location) - } - /** Converts a range of byte offsets in `self` to an `NSRange` suitable for filtering `self` as an `NSString`. diff --git a/Tests/SourceKittenFrameworkTests/StringTests.swift b/Tests/SourceKittenFrameworkTests/StringTests.swift index 1b0bc380..eb430af7 100644 --- a/Tests/SourceKittenFrameworkTests/StringTests.swift +++ b/Tests/SourceKittenFrameworkTests/StringTests.swift @@ -260,12 +260,6 @@ class StringTests: XCTestCase { } } -typealias LineRangeType = (start: Int, end: Int) - -func == (lhs: LineRangeType, rhs: LineRangeType) -> Bool { - return lhs.start == rhs.start && lhs.end == rhs.end -} - private func XCTAssertEqual(_ actual: (Int, Int)?, _ expected: (Int, Int), file: StaticString = #file, line: UInt = #line) { XCTAssertNotNil(actual, file: file, line: line)