Skip to content

Commit b7cdd5a

Browse files
authored
Merge pull request #1584 from ikesyo/remove-string-core-usages
2 parents f3cd96f + 6b9682f commit b7cdd5a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Foundation/NSString.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ open class NSString : NSObject, NSCopying, NSMutableCopying, NSSecureCoding, NSC
300300
}
301301
if type(of: self) == NSString.self || type(of: self) == NSMutableString.self {
302302
if _storage._guts._isContiguousASCII {
303-
return unsafeBitCast(_storage._core.startASCII, to: UnsafePointer<Int8>.self)
303+
return unsafeBitCast(_storage._guts.startASCII, to: UnsafePointer<Int8>.self)
304304
}
305305
}
306306
return nil
@@ -309,7 +309,7 @@ open class NSString : NSObject, NSCopying, NSMutableCopying, NSSecureCoding, NSC
309309
internal var _fastContents: UnsafePointer<UniChar>? {
310310
if type(of: self) == NSString.self || type(of: self) == NSMutableString.self {
311311
if _storage._guts._isContiguousUTF16 {
312-
return UnsafePointer<UniChar>(_storage._core.startUTF16)
312+
return UnsafePointer<UniChar>(_storage._guts.startUTF16)
313313
}
314314
}
315315
return nil
@@ -868,7 +868,7 @@ extension NSString {
868868
if type(of: self) == NSString.self || type(of: self) == NSMutableString.self {
869869
if _storage._guts._isContiguousASCII {
870870
used = min(self.length, maxBufferCount - 1)
871-
_storage._core.startASCII.withMemoryRebound(to: Int8.self,
871+
_storage._guts.startASCII.withMemoryRebound(to: Int8.self,
872872
capacity: used) {
873873
buffer.moveAssign(from: $0, count: used)
874874
}

0 commit comments

Comments
 (0)