Well formed XML? XML references within tag names and attribute names
I have been searching trying to confirm my reading of the XML spec.  My interpretation is that pre-defined entities and numeric character references are not allowed in tag names and attribute names, for example this is not allowed by the XML 1.0 spec.:

    <root>
    <test&apos;&#x27;&#39;tag test&apos;&#x27;&#39;attribute="one"/>
    </root>

However, I have one parser that returns **`test'''tag`** for the tag name and **`test'''attribute`** for the attribute name while another parser returns **`test&apos;&#x27;&#39;tag`** for the tag name and **`test&apos;&#x27;&#39;attribute`** for the attribute name.

Which parser is correct? Or are they both wrong (i.e. they should throw a well formed error)?

Thanks!



Well formed XML? XML references within tag names and attribute names
===

I have been searching trying to confirm my reading of the XML spec.  My interpretation is that pre-defined entities and numeric character references are not allowed in tag names and attribute names, for example this is not allowed by the XML 1.0 spec.:

    <root>
    <test&apos;&#x27;&#39;tag test&apos;&#x27;&#39;attribute="one"/>
    </root>

However, I have one parser that returns **`test'''tag`** for the tag name and **`test'''attribute`** for the attribute name while another parser returns **`test&apos;&#x27;&#39;tag`** for the tag name and **`test&apos;&#x27;&#39;attribute`** for the attribute name.

Which parser is correct? Or are they both wrong (i.e. they should throw a well formed error)?

Thanks!


