我正在使用Xcode 8并将项目更新为swift 3.当我在Xcode 8.1中打开我的工作区时,收到以下消息。
The targets “Alamofire” and “DBAlertController” contain source code developed with an earlier version of Swift.
DerivedData标记$ pod --version 1.2.0.beta.1
我已经清空了/Users/mark/Library/Developer/Xcode/DerivedData
Podfile
pod 'DBAlertController', :git => 'https://github.com/dbettermann/DBAlertController.git', :branch => 'swift3'
pod 'Alamofire', '~> 4.0'
Podfile
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '10.0'
use_frameworks!
我还运行了pod更新但没有修复它。
Marks-Mac:mark$ cd /Users/mark/Library/Developer/Xcode/DerivedData
Marks-Mac:DerivedData mark$ rm -rf *
Marks-Mac:DerivedData mark$ cd
Marks-Mac:~ mark$ cd Documents/myProject
Marks-Mac:mark$ pod update
Update all pods
Updating local specs repositories
Analyzing dependencies
Pre-downloading: `DBAlertController` from `https://github.com/dbettermann/DBAlertController.git`, branch `swift3`
Downloading dependencies
Installing AFNetworking (3.1.0)
Installing Alamofire (4.0.1)
Installing DBAlertController (0.3.0)
答案 0 :(得分:0)
关闭并打开Xcode,它似乎已经修复了自己找不到AFNetworking的头文件..