remove exception declarations that were not actually thrown