To report an error or a warning in a user defined function, use the methods
of Texinfo::Report
through a converter object
(see Converter Object and Conversion Functions).
To report a warning or an error not specific of an element conversion,
use document_warn
or document_error
:
Register a document-wide error or warning. $text is the error or warning message. The $converter object should be given as the second argument.
To report a warning or an error in element conversion, use
line_warn
or line_error
Register a warning or an error. $text is the text of the
error or warning. The $converter object should be given
as the second argument. The optional
$location_info holds the information on the error or
warning location. The $location_info reference on hash may be
obtained from Texinfo elements source_info
keys.
The optional $continuation argument, if set, conveys that the message
is a continuation of the previous registered message. The optional
$silent argument, if set, suppresses the immediate output of a message
if the DEBUG
customization variable is set.
In general, registering an error does not stop the processing, in particular it does not stop the main conversion of the Texinfo tree. Write initialization files as if the conversion always continued after registering the error.
See (texi2any_internals)Texinfo::Report for more on
Texinfo::Report
.