ios - 无法使用类型为“(String.UTF8View)”的参数列表调用类型 ‘UInt32’ 的初始化程序

标签 ios iphone swift swift3

无法使用 WibmoSDK 在 swift 3.0 中工作

让编码:CFStringEncoding = UInt32(String.Encoding.utf8)

我有像

这样的显示错误

"Cannot invoke initialiser for type ‘UInt32’ with an argument list of type ‘(String.UTF8View)"

最佳答案

尝试使用这个:

let encoding: CFStringEncoding = UInt32(String.Encoding.utf8.rawValue)

关于ios - 无法使用类型为“(String.UTF8View)”的参数列表调用类型 ‘UInt32’ 的初始化程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42389252/

相关文章:

ios - 将大多数非 UI 代码放在后台线程中?

带有范围按钮的导航栏中的 iOS 11 搜索 Controller

ios - 我们可以为一个 View Controller 使用两个不同的 Xib 吗?

ios - UITableView 内的 UITableViewCell

iphone - 转换 iPhone 音频文件的采样率

iphone - 当我使用 Three20 库时,我是否需要在应用商店提交过程中对使用加密的问题回答 "yes"?

swift - Mac的屏幕共享状态

ios - 使用 Google API 在 Objective C 中查询共享的 Google 日历

ios - 快速错误: fatal error: Cannot index empty buffer

iPhone - 使用 Sharekit 将图像发送到 Facebook