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: exported non-struct anonymous fields are not marshaled #3803

Closed
gopherbot opened this issue Jul 5, 2012 · 4 comments
Closed
Milestone

Comments

@gopherbot
Copy link

by dcampbell24:

latest version of Go: 1.0.2

What steps will reproduce the problem?

http://play.golang.org/p/sYqNwtYeh5

What is the expected output?

<A><B>0<B/></A>

What do you see instead?
<A></A>

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

Which operating system are you using?
Linux

Which version are you using?  (run 'go version')
weekly.2012-03-27 +100ddb84c85d

Please provide any additional information below.

The documentation for the xml package says that all exported fields are marshaled and
does not state any exception for embedded fields that are not structs.
@rsc
Copy link
Contributor

rsc commented Sep 12, 2012

Comment 2:

This may just be a doc fix.

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

Status changed to Accepted.

@rsc
Copy link
Contributor

rsc commented Sep 12, 2012

Comment 3:

Labels changed: added go1.1maybe.

@rsc
Copy link
Contributor

rsc commented Mar 12, 2013

Comment 4:

https://golang.org/cl/7743043

Labels changed: added go1.1, removed go1.1maybe.

Owner changed to @rsc.

Status changed to Started.

@rsc
Copy link
Contributor

rsc commented Mar 12, 2013

Comment 5:

This issue was closed by revision aa81eb5.

Status changed to Fixed.

@rsc rsc added this to the Go1.1 milestone Apr 14, 2015
@rsc rsc removed the go1.1 label Apr 14, 2015
@golang golang locked and limited conversation to collaborators Jun 24, 2016
@rsc rsc removed their assignment Jun 22, 2022
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