I provide support for a large dictionary editing project working with XML data. As part of this, I have to maintain some Perl programs which are used to check for errors in the content of the entries which cannot be found by parsing against an XML DTD. The scripts use XML Twig and LibXML.
We have recently found that these content validation scripts generate a "deep recursion" warning when run against one particular entry:
Report for entry lie, v.2 (id : 108042)
Deep recursion on subroutine "XML::LibXML::Error::as_string" at /usr/l
+.pm line 182, line 1.
I think the script is running correctly apart from this warning as it finds errors in the entry including some near the end (previous Perl errors have caused the script to bail out before finding every error)
One option I am considering is to switch it off but adding "no warnings 'recursion';" to the script does not turn the warning off.
So my questions are:
Is it safe to turn off the deep recursion warning?
How can I track down what in the entry might be causing the deep recursion?
Do I have to add the "no warnings 'recursion';" to the Error.pm script in LibXML to stop this message? As I said, I have tried adding it to my script but that does not stop the message.