Skip to content

Instantly share code, notes, and snippets.

@einarwh
Created June 27, 2014 21:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save einarwh/994d6a6ad4134e90cc59 to your computer and use it in GitHub Desktop.
Save einarwh/994d6a6ad4134e90cc59 to your computer and use it in GitHub Desktop.
All the dull code in one place.
TR Call<TR>(Func<TR> f) {
try {
return f();
}
catch (SomeException ex) {
// Dull code.
}
catch (SomeOtherException ex) {
// Dull code.
}
catch (YetAnotherException ex) {
// Dull code.
}
catch (Exception ex) {
// Dull code.
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment