Swiftyjson: Xcode 8 beta 6

Created on 16 Aug 2016  路  13Comments  路  Source: SwiftyJSON/SwiftyJSON

Library doesn't work with the latest Swift 3.0 release which is shipped with Xcode 8 beta 6. Perhaps somebody knows how to fix it?

Most helpful comment

All 13 comments

+1

I was able to make small changes in many places to update the syntax as needed, but I'm stumped on this last one. In SwiftyJSON.swift I have 10 errors that say something similar to:

Cannot invoke 'JSON.init' with an argument list of type '([AnyObject])'

Any ideas as to why the initializers aren't working?

@blwinters Changing AnyObject to Any should fix the problem.

@rudenik @haginile That did the trick. Thanks!

I got 62 errors in Xcode8 beta 6, these are some of them:
SwiftyJSON.swift:772:35: Expected ',' joining parts of a multi-clause condition
SwiftyJSON.swift:70:59: Value of type 'Any' does not conform to specified type 'AnyObject'
SwiftyJSON.swift:110:14: Cannot invoke 'JSON.init' with an argument list of type '([AnyObject])'
SwiftyJSON.swift:144:29: Return expression of type '[AnyObject]' does not conform to 'AnyObject'
SwiftyJSON.swift:146:29: Return expression of type '[String : AnyObject]' does not conform to 'AnyObject'
SwiftyJSON.swift:148:29: Return expression of type 'String' does not conform to 'AnyObject'
SwiftyJSON.swift:233:27: Use of unresolved identifier 'rawArray'
...........

@itman85 Check my previous post. The link has the answers you are looking for.

@rudenik Thank you

this pull request may help.

I used @rudenik 's solution. Works great, thanks. Let's get this fix merged!

@picciano Same here

Swift3 and Swift2.3 support is here

Closing this one to cleanup the issue list, feel free to reopen this if needed.

Cheers

Was this page helpful?
0 / 5 - 0 ratings

Related issues

artjomzab picture artjomzab  路  13Comments

Dershowitz011 picture Dershowitz011  路  15Comments

zhigang1992 picture zhigang1992  路  10Comments

frederik-jacques picture frederik-jacques  路  35Comments

KyeMaloy97 picture KyeMaloy97  路  12Comments