encoding.xml: make tag name and attribute parsing more robust and cleaner (#19828)

This commit is contained in:
Subhomoy Haldar 2023-11-10 09:31:36 +00:00 committed by GitHub
parent e59c194457
commit 00f2e4a8c5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 15 deletions

View file

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<sst count="5" uniqueCount="5">
<si>
<t>Item 1</t>
<t a="1">Item 1</t>
</si>
<si>
<t>Item 2</t>

View file

@ -19,6 +19,9 @@ fn test_valid_parsing() {
children: [
xml.XMLNode{
name: 't'
attributes: {
'a': '1'
}
children: ['Item 1']
},
]