>> First, Encodings::initMath should get the children like this. Please, >> use >> buffer->getChildren() for that. >> >> Now, we can avoid that getChildren() returns a list including itself. > >In other words, patch b? >
No, I refrain from words that other people might understand. I mean you shouldn't use the isChild function from Encoding::initMath. To fix the bugs, we should check for recursive includes when the InsetInclude changes (that's now done for document including itself; this should thus be checked for all relatives (bug 6305)), _and_ when the filename of the buffer changes (bug 6303). Just like Jmarc I don't like the ad-hoc approach of patch a, but neither the ad-hoc approach of patch b :).. Checking only for the simple recursive case in the isChild function, because some function somewhere uses a homegrown method to get all children does not pass my ad-hoc-test. First the isChild function shouldn't be used, second I don't expect this behaviour of the isChild function. If A includes A, I expect A->isChild(A) to return true. As stated above, instead we should avoid having a situation that A includes A. Vincent