Bug 1925 – Not all xml empty tags are recognized

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2008-03-15T16:12:00Z
Last change time
2015-06-09T01:14:37Z
Assigned to
caron800
Creator
ar_other

Comments

Comment #0 by ar_other — 2008-03-15T16:12:51Z
If empty tag in xml document doesn't have space before '/' symbol parser treats is as a start tag. E.g. <b/> is recognized as a start tag which name is 'b/', but <b /> is parsed correctly. It seems that '/' symbol must be added to string "^>" in line #786 in std\xml.d. name = munch(s,"^>"~whitespace); => name = munch(s,"^>/"~whitespace);
Comment #1 by caron800 — 2008-03-15T17:18:15Z
On 15/03/2008, [email protected] <[email protected]> wrote: > If empty tag in xml document doesn't have space before '/' symbol parser treats > is as a start tag. E.g. <b/> is recognized as a start tag which name is 'b/', > but <b /> is parsed correctly. > > It seems that '/' symbol must be added to string "^>" in line #786 in > std\xml.d. > name = munch(s,"^>"~whitespace); > => > name = munch(s,"^>/"~whitespace); Ooh - I guess that makes it the first bug that falls to me to fix! Thanks for pointing it out. Will fix promptly.
Comment #2 by bugzilla — 2008-05-11T04:15:55Z
Fixed dmd 2.013