When I set c to a
c
a
var a: [Any] var c: Array<PostCategory>
error shown:
cannot convert value of type 'Array' to expected argument type [Any]
how to solve the problem?
The error message is a bit misleading but try initializing the array before assigning it:
var c: Array<PostCategory> = []
...or...
var c = Array<PostCategory>()
1.4m articles
1.4m replys
5 comments
57.0k users