如何在 iOS 中声明一个 weakSelf 对象

How to declare a weakSelf object in iOS

有什么区别:

__weak __typeof(&*self)weakSelf = self

__weak __typeof(self)weakSelf = self

有人知道吗?

使用0xced的回答:

In the latest clang version Apple clang version 4.0 (tags/Apple/clang-421.1.48) (based on LLVM 3.1svn), i.e. Xcode 4.4+, the __typeof__((__typeof__(self))self) trick is not necessary anymore. The __weak typeof(self) bself = self; line will compile just fine.