I much prefer Andre's way. Compare

        InsetSomething * i = inset->asSomethingInset();
        if (!i)
                break;

with

        if (inset->lyxCode() == SOMETHING_CODE) {
                InsetSomething * i = static_cast<InsetSomething*>(i);
                ...
        }

Does anyone have a problem with this form of RTTI ?

regards
john
-- 
""All the people we like are We, and everyone else is They."
        - Kipling

Reply via email to