fix losing flags during structure-type copy
this comment is now irrelevant