let detector:CIDetector=CIDetector(ofType: CIDetectorTypeQRCode, context: nil, options: [CIDetectorAccuracy:CIDetectorAccuracyHigh])!
它在设备中运行良好,但是在为 iTunes 分发生成构建时会出现错误:
“'[String:AnyObject] 类型的值?” 没有成员“钥匙”
如果我删除选项部分
[CIDetectorAccuracy:CIDetectorAccuracyHigh]
然后它给出如下错误:
(ofType: String, context: CIContext?, options: [String : AnyObject]?) -> CIDetector' 不能转换为 '(ofType: String, context: CIContext?, options: [String : AnyObject]?) -> CIDetector ?
有人对此有想法吗?
我正在使用 Swift 2.3 和 Xcode 8.1。