Can we forbid weak keyword for computed properties?

I don’t think that analogy between weak and IUO is correct. IUO is a transitional technology, and so probably is unowned(unsafe), but I’m pretty sure weak and unowned are here to stay. Some mechanism to support weak references is essential for any reference-counting-based system and Swift is not an exception. Even if two will be merged into one for simplicity in the future (hypothetically), at least one of them will remain for sure.

@michelf, do you see any problems with using weak references as types in these or any other cases?

  • using weak reference as a type of element/key/value of the container
  • using weak reference as a type of function argument/result
  • returning weak reference type when inspecting object using Mirror