0

I have a class with a weak var,

for example :

class Foo {

    weak var myVar : UILabel!
}

If a build a subclass, can I override the property without the weak key?

I tried with the following code but I received :

class Foo2 : Foo{
    override var myVar : UILabel!
}

"Cannot override with a stored property" error.

If it's possible to do, how can I do?

Prashant Tukadiya
  • 15,838
  • 4
  • 62
  • 98

0 Answers0