Re: [xml] xmllint as minimal non-validating parser?



Aack! I forgot to specify my platform and libxml2 version:

  Linux (Ubuntu 7.04)
  xmllint: using libxml version 20627

Chuck

On Thu, Sep 13, 2007 at 04:33:37PM -0500, Chuck Bearden wrote:
My reading of the XML Recommendation:
The well-formedness constraint "Entity Declared" [1] does not apply
to an XML document with an external DTD subset and which does not
have a standalone declaration of 'no', since on-validating processors
are not required to read external DTD subsets.  Such a document may
contain internal general entity references that aren't defined in an
internal DTD subset and nonetheless be well-formed.

The attached well-formed, valid document contains a reference to an
entity defined in the external DTD subset.  However, I can't find a
way to make xmllint treat it as well-formed:

  $ xmllint --noout --noent Briantest.xml
  Briantest.xml:20: parser error : Entity 'plus' not defined
      <m:mo>&plus;</m:mo>
                  ^
  $ xmllint --noout Briantest.xml
  Briantest.xml:20: parser error : Entity 'plus' not defined
      <m:mo>&plus;</m:mo>
                  ^
  $

Is there a way to make xmllint do no more than check documents
against the well-formedness constraints, to emulate a minimal
non-validating processor?

[1] <http://www.w3.org/TR/2006/REC-xml-20060816/#wf-entdeclared>

Thanks in advance!
Chuck
--
Chuck Bearden (cbearden rice edu ; 713.348.3661)
XML Engineer, Connexions
http://cnx.org/


_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
xml gnome org
http://mail.gnome.org/mailman/listinfo/xml




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]