简体   繁体   中英

No such module, swift, xcode 6.2

Here is a screenshot:

.h module, as you can see, copied in project, but Xcode ignore it. I'd try uninstall XCode and install 6.2 (beta 5), In Terminal, I tried

rm -rf ~/Library/Developer/Xcode/DerivedData ,
defaults delete com.apple.dt.Xcode...

but it didn't help.

Because you are using objective-c files, you need to add the .h file to your Bridging-Header.h file. This file was generated by Xcode itself but it's currently empty.

So open Bridging-Header.h and add the following line:

#import "QRCode.h"

请添加头文件并导入文件。使用Swift本身需要进行接口连接。

您可以在不导入模块的情况下使用该模块,因为您拖动了项目中的swift文件而不是二进制文件。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM