Closed JRG-Developer closed 8 years ago
Add @noescape attributes to decorate the closures.
@noescape
This has two nice benefits: (1) Eliminates need for self inside the closure. (2) Small compiler optimizations
self
Even if a call is made inside the closure that isn't @noesacpe, this is okay: it only matters about the closure itself.
@noesacpe
For more details, see here:
http://nshint.io/blog/2015/10/23/noescape-attribute/
Per my testing, this is also full backwards-compatible too.
That is, even if you did do the [weak self] dance, it's all still good.
[weak self]
💃
will bump the version soon
Add
@noescape
attributes to decorate the closures.This has two nice benefits: (1) Eliminates need for
self
inside the closure. (2) Small compiler optimizationsEven if a call is made inside the closure that isn't
@noesacpe
, this is okay: it only matters about the closure itself.For more details, see here:
http://nshint.io/blog/2015/10/23/noescape-attribute/