Skip to content

Instantly share code, notes, and snippets.

@MylesCaley
Created December 8, 2016 14:10
Show Gist options
  • Save MylesCaley/2e379843b4dca9294a075f751b80e19c to your computer and use it in GitHub Desktop.
Save MylesCaley/2e379843b4dca9294a075f751b80e19c to your computer and use it in GitHub Desktop.
pattern for weak closure
{ [weak self] (_) in
guard let _ = self else { return }
self!.
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment