Skip to content

Instantly share code, notes, and snippets.

@fragamus
Created September 13, 2018 23:58
Show Gist options
  • Save fragamus/9e472a78922c58b420bc164d06fa7645 to your computer and use it in GitHub Desktop.
Save fragamus/9e472a78922c58b420bc164d06fa7645 to your computer and use it in GitHub Desktop.
So withSome just identifies the selector right
import Data.Some
asdf :: forall a. Maybe a -> Bool
asdf (Just _) = True
asdf Nothing = False
test1 = withSome (This (Just 5)) asdf
test2 = withSome (This Nothing) asdf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment