Restrict xml build reversal to Annotations

I think this order should probably be reversed for a wider range of
elements but a general reversal causes problems with the
AbstractProprietary elements. Restricted to just Annotation to
get the code working. Only Annotations have abstract types with
elements, so only they need this fix at the moment.