Hmmm ... so you're suggesting that if we leave things as they are, then an ODD that had just <schemaSpec> <moduleRef key="tei"/> <moduleRef key="header"/> <moduleRef key="core"/> <moduleRef key="textstructure"/> </schemaSpec> would produce incorrect schemas because <xenoData> of 'header' wants macro.anyXML which will not be there? Well, I just tried it, and you are absolutely right. (The good news is that the ODD processor does not generate an invalid schema. The bad news is that, as you predicted, it does not produce the right schema, either.) I will fix this as soon as I hear from Hugh as to whether I should fix it in sydb-xenodata, master, or do something else.
The anyXML thing is not quite as you describe it. if the macro is declared in the tagdocs module, as it currently is, then you won't get it unless you include that module in your schema. If you want to use it in xenodata, then you need to declare it in the infrastructure module. the @predeclare thing is not really relevant: it is a legacy piece of trickery whjich we should not be using. Just move the declaration to the infrastructure module and add the appropriate text into chapter ST would be my recommendation.