Files
craft-libs/crates
Claude fb59c587df print: respell refuses a nested redeclaration; test the vendor-element case for real
Review of #307:

- respell rewrites the root's namespace declarations, so an element below the
  root that declares either prefix of a rename again (ns0000 or brpsk) would make
  a name resolve to another namespace once the prefixes change. It now returns
  None for such a ticket, and a test covers both prefixes.
- The vendor-element test replaced only an opening tag, left the closing tag
  behind and so never parsed: it passed because respell refused the broken XML,
  not because of what it was meant to check. Every refusal fixture is now
  asserted well-formed, and the element is replaced whole. Doing so showed the
  element guard was redundant: an element or attribute name in a renamed
  namespace leaves an undeclared prefix, which the final parse of the result
  already refuses. The guard is removed and the test now exercises that check.
- Doc comments on the new constants and tests.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FQ5PzHVUcntEHU97znim5u
2026-10-25 02:06:11 +00:00
..