Skip to content

Instantly share code, notes, and snippets.

@brianschmitt
brianschmitt / Find-Empty-Catch Blocks
Last active December 11, 2019 21:18
Find Empty Catch Blocks - Visual Studio Regex
//Find Dialog - Use Regular Expressions - works for both C# and VB
catch.*[\r?\n\s]*((End Try)|({\s*\r?\n*}))
//For older versions of Visual Studio:
catch.*\n+:b+((End Try)|(\{[:b\n]+\}))