File tree Expand file tree Collapse file tree 2 files changed +2
-10
lines changed Expand file tree Collapse file tree 2 files changed +2
-10
lines changed Original file line number Diff line number Diff line change @@ -42,8 +42,8 @@ public func readLine(strippingNewline: Bool = true) -> String? {
42
42
// <rdar://problem/20013999> Recognize Unicode newlines in readLine()
43
43
//
44
44
// Recognize only LF and CR+LF combinations for now.
45
- let cr = CChar ( _ascii8 ( " \r " ) )
46
- let lf = CChar ( _ascii8 ( " \n " ) )
45
+ let cr = CChar ( UInt8 ( ascii : " \r " ) )
46
+ let lf = CChar ( UInt8 ( ascii : " \n " ) )
47
47
if readBytes == 1 && linePtr [ 0 ] == lf {
48
48
return " "
49
49
}
Original file line number Diff line number Diff line change @@ -267,14 +267,6 @@ extension UnicodeScalar.UTF16View : RandomAccessCollection {
267
267
}
268
268
}
269
269
270
- /// Returns c as a UTF8.CodeUnit. Meant to be used as _ascii8("x").
271
- @warn_unused_result
272
- public // SPI(SwiftExperimental)
273
- func _ascii8( _ c: UnicodeScalar ) -> UTF8 . CodeUnit {
274
- _sanityCheck ( c. value >= 0 && c. value <= 0x7F , " not ASCII " )
275
- return UTF8 . CodeUnit ( c. value)
276
- }
277
-
278
270
/// Returns c as a UTF16.CodeUnit. Meant to be used as _ascii16("x").
279
271
@warn_unused_result
280
272
public // SPI(SwiftExperimental)
You can’t perform that action at this time.
0 commit comments