简体   繁体   English

获得Swift编译器错误

[英]Getting Swift compiler errors

I've built an app in Xcode 6.2 and it was running fine but when I moved it Xcode 6.3 on another system I'm getting a lot of Swift compiler errors. 我在Xcode 6.2构建了一个应用程序并且它运行正常但是当我在另一个系统上移动Xcode 6.3 ,我收到了很多Swift编译器错误。

Most of them are like "AnyObject is not convertible to NSArray" , "AnyObject is not convertible to NSNumber" 大多数都像"AnyObject is not convertible to NSArray""AnyObject is not convertible to NSNumber"

Sorry I could not upload any image. 抱歉,我无法上传任何图片。

I would strongly advise reading the release notes in order to get a rough idea of what has/hasn't been changed. 我强烈建议阅读发行说明 ,以便大致了解已经/未被更改的内容。

There are some major syntactic modifications and a few depreciations, which you will have to manually fix in your code. 有一些主要的语法修改和一些折旧,您必须在代码中手动修复。

For the problem of anyObjects I can help you. 对于anyObjects的问题,我可以帮助你。 You can replace anyObjects by "first" so there is nothing difference. 你可以用“first”替换anyObjects,这样就没什么区别了。 Also there are a lot of changes, likes, when you have to put as, you also have to put an ! 还有很多变化,喜欢,当你必须把它,你也必须放一个! (as!) like "name as! SKNode()". (如!),如“name as!SKNode()”。 You can take a look to the release nodes for more information. 您可以查看发布节点以获取更多信息。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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