daily pastebin goal
10%
SHARE
TWEET

Untitled

a guest Nov 15th, 2017 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Result<T> MyFunction()
  2.    
  3. public ParseFailure<TOther> As<TOther>()
  4. {
  5.     return new ParseFailure<TOther>(_input, _message, _expectations);
  6. }
  7.    
  8. Result<OldType> firstResult = ...
  9. if (firstResult.Failed) return firstResult.As<NewType>();
  10.    
  11. if (firstResult.Failed) return firstResult;
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top