Exception macro refactor