Skip to content

Instantly share code, notes, and snippets.

@endash
Last active February 24, 2016 17:06
Show Gist options
  • Save endash/ad9237a3a8eae1258983 to your computer and use it in GitHub Desktop.
Save endash/ad9237a3a8eae1258983 to your computer and use it in GitHub Desktop.
let opt: ((NSColor) -> Bool)? = nil
let nonOpt = {(aColor: NSColor) in return true }
let coalesced = opt ?? nonOpt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment