Does renaming it to Xerces.cpp make any difference?
Yes it does! MANIFEST hast to be updated, too. -
Another issue are the compiler flags. Currently they are not taken from "Config.pm", it seems. So I copied the following from there:
-DWIN32 -D_CONSOLE -DNO_STRICT -DHAVE_DES_FCRYPT -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -DPERL_MSVCRT_READFIX
Apparently only "-DWIN32" is really needed. Then I added the following:
-D_REENTRANT -TP -GX -DHAS_BOOL
Without "-DHAS_BOOL" a lot of "unresolved external ..." linker errors are produced. -TP forces C++ compilation (not needed if the file is named *.cpp), -GX is asked for by the compiler.
Now I see the message is *not* always "Handling Unknown exception".
Ok, that's better.
Here is another test case (copied from SAXException.t and modified):
my $parser = XML::Xerces::XMLReaderFactory::createXMLReader();
eval {
$parser->setFeature("http://xml.org/sax/features/foospaces", 0);
};
my $ex = $@;
print $ex;
print $ex->getMessage();prints:
"Handling Unknown exception at D:\Scripts\perl\testXML-Xerces-Exceptions.pl line 9. XML::Xerces::SAXNotRecognizedException=HASH(0x1a754bc)"
The proper exception type is generated, but the "getMessage" method (an alias for XML::Xercesc::SAXException_getMessage) fails and dies saying "Handling Unknown exception". -
Xerces.pm: $VERSION = q[1.7.0-1]; should be updated.
Martin
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
