File tree Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Original file line number Diff line number Diff line change @@ -414,11 +414,11 @@ extension String {
414
414
if ptr != nil {
415
415
return try body ( UnsafeBufferPointer ( start: ptr, count: _core. count) )
416
416
}
417
- var nulTerminatedUTF8 = ContiguousArray < UTF8 . CodeUnit > ( )
418
- nulTerminatedUTF8 . reserveCapacity ( utf8. count + 1 )
419
- nulTerminatedUTF8 += utf8
420
- nulTerminatedUTF8 . append ( 0 )
421
- return try nulTerminatedUTF8 . withUnsafeBufferPointer ( body)
417
+ var nullTerminatedUTF8 = ContiguousArray < UTF8 . CodeUnit > ( )
418
+ nullTerminatedUTF8 . reserveCapacity ( utf8. count + 1 )
419
+ nullTerminatedUTF8 += utf8
420
+ nullTerminatedUTF8 . append ( 0 )
421
+ return try nullTerminatedUTF8 . withUnsafeBufferPointer ( body)
422
422
}
423
423
424
424
/// Creates a string corresponding to the given sequence of UTF-8 code units.
@@ -720,9 +720,4 @@ extension String {
720
720
public var nulTerminatedUTF8 : ContiguousArray < UTF8 . CodeUnit > {
721
721
Builtin . unreachable ( )
722
722
}
723
-
724
- @available ( * , unavailable, renamed: " utf8CString " )
725
- public var nulTerminatedUTF8CString : ContiguousArray < CChar > {
726
- Builtin . unreachable ( )
727
- }
728
723
}
You can’t perform that action at this time.
0 commit comments