Add support for exception handling