mirror of
https://github.com/apple/swift.git
synced 2026-11-30 09:15:01 +01:00
char32_t can hold values that are not valid Unicode scalars, so importing it as Unicode.Scalar is unsound. CChar32 is now UInt32. Callers that want validation should use Unicode.Scalar's failable initializer. Code that uses Unicode.Scalar directly in @_cdecl and @objc declarations still prints as char32_t in generated headers. Compilers without the CChar32IsUInt32 feature, added in the previous commit, still see CChar32 as Unicode.Scalar. rdar://179235116