Further work and tidying of error highlighting