Mark type of thrown errors. Closes #153