annotate xml elements with location information and use that in error messages