I am trying to convert one function to newer Swift3 version but getting error. The action is happening in UICollectionViewLayoutAttributes class which is called CircularCollectionViewLayoutAttributes and class starts like:
class CircularCollectionViewLayoutAttributes: UICollectionViewLayoutAttributes { ...
function code:
override func copy(with zone: NSZone? = nil) -> Any {
let copiedAttributes: CircularCollectionViewLayoutAttributes = super.copy(zone) as! CircularCollectionViewLayoutAttributes
copiedAttributes.anchorPoint = self.anchorPoint
copiedAttributes.angle = self.angle
return copiedAttributes
}
I almost managed to transform it, but still one error on line:
let copiedAttributes: CircularCollectionViewLayoutAttributes = super.copy(zone) as! CircularCollectionViewLayoutAttributes
says that: "Argument passed to call that takes no arguments" and underlines "zone".
Your help is very appreciated.