Skip to content

Instantly share code, notes, and snippets.

@bartelink bartelink/gist:8720521 forked from horsdal/gist:8677391
Last active Aug 29, 2015

Embed
What would you like to do?
public static TRes Match<T,TRes>(this FSharpOption<T> opt, Func<T,TRes> some, Func<TRes> none)
{
if (FSharpOption<T>.get_IsSome(opt))
return some.Invoke(opt.Value);
else
return none.Invoke();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.