[PATCH] XML validity of kcfg files

Christian Mueller cmueller at gmx.de
Sat Oct 30 18:52:57 BST 2004

Am Samstag, 30. Oktober 2004 19:18 schrieb Aaron J. Seigo:
> On Saturday 30 October 2004 10:38, Thiago Macieira wrote:
> > Aaron J. Seigo wrote:
> > >except for the Stringlist -> StringList change, they all seem to just be
> > >reordering of the tags, e.g. max after default instead of before. does
> > >re-ording the tags really make any difference? sounds to me like the
> > > script is reporting a lot of false positives?
> >
> > The reordering could be mandated by the DTD.
> yes, but it isn't. 

Sorry, but it is: 

For example, take this line from the DTD: 

 <!ELEMENT entry (parameter?,label?,whatsthis?,choices?,code?,default*,min?,max?)>

That means that the subelements must appear in exactly that order
(if they are present, "?" and "*" allow elements to appear "zero times"). 

Everything else is invalid XML.  What's the point of defining a DTD 
if you're never validating your documents against it?   The kconfig_compiler 
does not seem to care (maybe it should also validate?) but still a wrong order 
is invalid XML.  

Those are no false positives as far as the XML is concerned. 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20041030/21d0d1fc/attachment.sig>

More information about the kde-core-devel mailing list