The parser can be used to validate a document. This means that all the constraints that must hold for a valid document are actually checked. Validation is the default mode of Markup, i.e. every document is validated while it is being parsed.
In the examples directory of the distribution you find the validate application. It is invoked in the following way:
validate [ -wf ] file...The files mentioned on the command line are validated, and every warning and every error messages are printed to stderr.
The -wf switch modifies the behaviour such that a well-formedness parser is simulated. In this mode, the ELEMENT, ATTLIST, and NOTATION declarations of the DTD are ignored, and only the ENTITY declarations will take effect. This mode is intended for documents lacking a DTD. Please note that the parser still operates as validator, with some features switched off; the average well-formedness parser that is currently being offered everywhere simply ignores declarations.
The validate application is the simplest sensible program using Markup, you may consider it as "hello world" program.