Skip to content

Instantly share code, notes, and snippets.

@stoeckley
Created December 23, 2017 21:13
Show Gist options
  • Save stoeckley/65303cf2177283fa8d77842ed8294b9c to your computer and use it in GitHub Desktop.
Save stoeckley/65303cf2177283fa8d77842ed8294b9c to your computer and use it in GitHub Desktop.
swift comma operator
if (foo != nil && bar > foo!) || foo == nil {
// something
}
if let foo = foo, bar > foo || self.foo == nil {
// something
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment