Skip to content

Return the document string value to XPath expressions - #85

Open
rudycelekli wants to merge 1 commit into
antchfx:masterfrom
rudycelekli:fix/document-string-value-20261101
Open

rudycelekli wants to merge 1 commit into
antchfx:masterfrom
rudycelekli:fix/document-string-value-20261101

Conversation

@rudycelekli

Copy link
Copy Markdown

The root document navigator reports an empty value even when descendant elements contain text. As a result, string(/), root-context string() and contains(/, ...) disagree with the XPath root-node string value. Reuse InnerText for the document node. Tests retain element/comment controls. Oracle: https://www.w3.org/TR/1999/REC-xpath-19991116/#root-node .

Validation at e752c2849465b79717ba207419adfbd8f1479b78 (base c81db40582f5291b74718efa78706f6537ba29b6):

  • Added regression fails on the unchanged base.
  • go test ./... -count=1 passes.
  • go test -race ./... -count=1 passes.
  • git diff --check passes.

Checks above ran locally on macOS; hosted CI and maintainer review remain separate. Prepared and independently reviewed with Codex assistance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant