Commit 38c561cb authored by Igor Vashyst's avatar Igor Vashyst Committed by Brad Fitzpatrick

encoding/xml: remove duplicate test of element presence

Change-Id: If0d9ff107fc6bbdf0231cd48abc23a44816bfe77
Reviewed-on: https://go-review.googlesource.com/85755Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
parent 0770aaca
...@@ -583,16 +583,6 @@ var marshalTests = []struct { ...@@ -583,16 +583,6 @@ var marshalTests = []struct {
ExpectXML: `<PresenceTest></PresenceTest>`, ExpectXML: `<PresenceTest></PresenceTest>`,
}, },
// A pointer to struct{} may be used to test for an element's presence.
{
Value: &PresenceTest{new(struct{})},
ExpectXML: `<PresenceTest><Exists></Exists></PresenceTest>`,
},
{
Value: &PresenceTest{},
ExpectXML: `<PresenceTest></PresenceTest>`,
},
// A []byte field is only nil if the element was not found. // A []byte field is only nil if the element was not found.
{ {
Value: &Data{}, Value: &Data{},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment