You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add an upcall point to swift-corelibs-foundation for String encoding conversion (#1217)
* Add an upcall point to swift-corelibs-foundation for String encoding conversion
* Add upcall for conversion from bytes to String in non-swift-foundation encodings
// ISO Latin 1 encodes code points 0x0 through 0xFF (a maximum of 2 UTF-8 scalars per ISO Latin 1 Scalar)
226
234
// The UTF-8 count is a cheap, reasonable starting capacity as it is precise for the all-ASCII case and it will only over estimate by 1 byte per non-ASCII character
@@ -241,13 +249,14 @@ extension String {
241
249
buffer.appendElement(value)
242
250
}
243
251
}
244
-
#endif
252
+
#endif
245
253
default:
246
254
#if FOUNDATION_FRAMEWORK
247
255
// Other encodings, defer to the CoreFoundation implementation
0 commit comments