Be smarter about renaming catch parameters.

Fixes #154.