[xsd-users] possible break in exception hieracy?

Bradley Beddoes beddoes at intient.com
Tue Jan 16 07:08:20 EST 2007


My problem below was and std::map of namespaces being truncated during 
copy from where it is defined for some reason which I yet to figure out 
and stumped by, the exception hierarchy question still stands.

Bradley Beddoes wrote:
> Hi Boris,
> At the moment I am having some problems with my serialization  functions 
> and couldn't seem to find what exception was being thrown.
> 
> After some careful tracing I tracked it to this in elements.txx:
> 
> if (p == 0)
>           {
>             if (e.isDefaultNamespace (xns.c_str ()))
>             {
>               return std::basic_string<C> ();
>             }
>             else
>             {
>               // 'xml' prefix requires special handling and Xerces folks
>               // refuse to handle this in DOM so I have to do it myself.
>               //
>               if (ns == xml::bits::xml_namespace<C> ())
>                 return xml::bits::xml_prefix<C> ();
> 
>               throw no_prefix ();
>             }
>           }
> 
> See how your throwing no_prefix() ? is that correct? The class no_prefix 
> seems to be forward decl in elements.hxx but doesn't seem to be 
> implemented from what I can see? It certainly doesn't appear to be part 
> of the exceptions hierachy.
> 
> I cant quite understand why I am reaching this point to be honest, at 
> the moment I am struggling with a serialization issue where if I feed 
> the serializer an appropriate DOM element ( using overloaded << ) it 
> will work the first time without problem, reseting all my pointers and 
> so forth and running again results in this namespace conflict. It almost 
> seems like I am not closing something properly, any ideas? I will stay 
> on it with the debugger and let you know if I find the problem.
> 


-- 
Bradley Beddoes
Lead Software Architect

Intient - "Open Source, Open Standards"




More information about the xsd-users mailing list