Bug 3088 – std.xml.check() fails on xml comments

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2009-06-23T14:32:00Z
Last change time
2015-06-09T01:26:55Z
Assigned to
rsinfu
Creator
andrew.talbot

Comments

Comment #0 by andrew.talbot — 2009-06-23T14:32:40Z
std.xml.check() seems not to recognize the end of an xml comment. For example, when the following code is run with the given data file it produces the error messages shown below. prog.d: import std.xml; void main() { string s = cast(string)std.file.read("data.xml"); check(s); } data.xml: <?xml version="1.0"?> <set> <one>A</one> <!-- comment --> <two>B</two> </set> Output messages: Line 5, column 16: Expected literal "-->" Line 5, column 16: Literal Line 4, column 5: Comment Line 4, column 5: Content Line 2, column 1: Element Line 1, column 1: Document
Comment #1 by b.helyer — 2009-10-19T05:46:26Z
Changed this to all, because it happens over here (x86) too.
Comment #2 by rsinfu — 2010-05-23T21:33:21Z
Fixed in svn r1549.