catch evaluation errors in compiler