Is there a better way to ignore an exception in C# than putting it up in a try catch block and doing nothing in catch? I find this syntax to be cumbersome. For a codeblock,
public static void Ignore(Action a) where T : Exception { try { a(); } catch (T) { } }
To use:
Ignore(() => foo());