Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

encoding/xml: document behavior for unknown name spaces #5626

Closed
gopherbot opened this issue Jun 3, 2013 · 5 comments
Closed

encoding/xml: document behavior for unknown name spaces #5626

gopherbot opened this issue Jun 3, 2013 · 5 comments

Comments

@gopherbot
Copy link

by jim.robinson:

What steps will reproduce the problem?
If possible, include a link to a program on play.golang.org.

1. http://play.golang.org/p/iQ4OLccNYW

What is the expected output?

An error message on the first token, due to an attribute

  c:missing-namespaces="yes"

defined without any namespace declaration for the prefix 'c'.

What do you see instead?

successful log output on each token parsed

Which compiler are you using (5g, 6g, 8g, gccgo)?

6g

Which operating system are you using?

darwin

Which version are you using?  (run 'go version')

go version devel +6dad366e9f94 Mon Jun 03 16:44:35 2013 -0400 darwin/amd64
@rsc
Copy link
Contributor

rsc commented Jun 4, 2013

Comment 1:

If the name space is not known, then package xml records the prefix instead. This helps
when people are parsing xml fragments. Yes, it's not strictly okay, but it's also not
hurting anything to handle that case.

Status changed to WorkingAsIntended.

@gopherbot
Copy link
Author

Comment 2 by jim.robinson:

Then could the documentation be extended to indicate this?  Right
the parser documentation simply states:
    // Strict defaults to true, enforcing the requirements
    // of the XML specification.
which certainly implies it will follow the spec.

@rsc
Copy link
Contributor

rsc commented Jun 21, 2013

Comment 3:

Labels changed: added priority-later, go1.2, removed priority-triage.

Status changed to Accepted.

@rsc
Copy link
Contributor

rsc commented Sep 10, 2013

Comment 4:

Labels changed: added documentation.

@rsc
Copy link
Contributor

rsc commented Sep 15, 2013

Comment 5:

This issue was closed by revision 1385e39.

Status changed to Fixed.

@rsc rsc added this to the Go1.2 milestone Apr 14, 2015
@rsc rsc removed the go1.2 label Apr 14, 2015
@golang golang locked and limited conversation to collaborators Jun 24, 2016
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants