Thomas Conway added the comment: Hi Martin,
You write: It's not a bug in toxml, which should always serialize the DOM tree if possible. Right! In this case it is *not* possible. The generated serialization is not a well formed XML document. Having just consulted the DOM technical reports, I see that createComment is specified as not generating any exceptions, so although it would be quite a sensible place to check that one was not creating an insane document, probably one should not do the check there. I think you're right that this *is* a bug in DOM, and I will report it there. Having said that, I still think that toxml should throw an exception. In general, if toxml succeeds, I would expect to be able to parse the result. I can propose a doco change, but I think such would only be a partial solution. Something like the following addition to the description for createComment Note that comments containing the string C{-->} may make the document unserializable. cheers, Tom __________________________________ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue1390> __________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com