@@ -297,7 +297,7 @@ open class NSString : NSObject, NSCopying, NSMutableCopying, NSSecureCoding, NSC
297297
298298 internal func _fastCStringContents( _ nullTerminated: Bool ) -> UnsafePointer < Int8 > ? {
299299 if type ( of: self ) == NSString . self || type ( of: self ) == NSMutableString . self {
300- if _storage. _core . isASCII {
300+ if _storage. _guts . _isContiguousASCII {
301301 return unsafeBitCast ( _storage. _core. startASCII, to: UnsafePointer< Int8> . self )
302302 }
303303 }
@@ -306,7 +306,7 @@ open class NSString : NSObject, NSCopying, NSMutableCopying, NSSecureCoding, NSC
306306
307307 internal var _fastContents : UnsafePointer < UniChar > ? {
308308 if type ( of: self ) == NSString . self || type ( of: self ) == NSMutableString . self {
309- if ! _storage. _core . isASCII {
309+ if _storage. _guts . _isContiguousUTF16 {
310310 return UnsafePointer < UniChar > ( _storage. _core. startUTF16)
311311 }
312312 }
@@ -315,7 +315,7 @@ open class NSString : NSObject, NSCopying, NSMutableCopying, NSSecureCoding, NSC
315315
316316 internal var _encodingCantBeStoredInEightBitCFString : Bool {
317317 if type ( of: self ) == NSString . self || type ( of: self ) == NSMutableString . self {
318- return !_storage. _core . isASCII
318+ return !_storage. _guts . _isContiguousASCII
319319 }
320320 return false
321321 }
@@ -858,7 +858,7 @@ extension NSString {
858858 public func getCString( _ buffer: UnsafeMutablePointer < Int8 > , maxLength maxBufferCount: Int , encoding: UInt ) -> Bool {
859859 var used = 0
860860 if type ( of: self ) == NSString . self || type ( of: self ) == NSMutableString . self {
861- if _storage. _core . isASCII {
861+ if _storage. _guts . _isContiguousASCII {
862862 used = min ( self . length, maxBufferCount - 1 )
863863 _storage. _core. startASCII. withMemoryRebound ( to: Int8 . self,
864864 capacity: used) {
0 commit comments