蓝牙智能锁从swift3兼容swift5

351 阅读1分钟

源码地址

先来个项目整体效果图

01.png
02.png

一 This workspace has projects that contain source code developed with Swift 3.x. This version of Xcode does not support building or migrating Swift 3.x targets. Use Xcode 10.1 to migrate the code to Swift 4.

Xcode安装多个版本并自动切换版本

二 The “Swift Language Version” (SWIFT_VERSION) build setting must be set to a supported value for targets which use Swift. Supported values are: 3.0, 4.0, 4.2. This setting can be set in the build settings editor.

1.更新三方sdk到最新 2.更改三方库build至swift5

项目run起来后的报错,

eeror.png
发觉大多错误是三方库升级后部分参数变化导致,原swift语法未有较大不兼容