Lars Gullik Bjønnes wrote:

> Angus Leeming <[EMAIL PROTECTED]> writes:
> 
> | Attached is a simple sample showing how I could use boost::any to
> | implement the transformation stuff in InsetExternal.
> 
> I do not agree with how you use operatesOn.

Thanks for the feedback. I'm feeling my way here.

> Of course this functions really should just throw if wrong factory is
>  used, and not return a empty ptr in that case

Overkill. The empty pointer test is perfectly adequate.

> | I think it results in very elegant code, but the killer is the
> | try,catch block. The block is needed, so I guess that this means I
> | cannot use the appropach within lyx?
> 
> If we all agree that we want to use exceptions, I am all for it.
> But that is up to the rest of you.

What compilers are preventing us from doing this now? I read that gcc 2.95 
supports exceptions and that seems to be our worst case compiler.

> But I would rewrite a bit further to make it even simpler...

Sure. That's why I post these things ;-)

-- 
Angus

Reply via email to