On Tue, Aug 31 2010, Andy Wingo wrote: > Hi, > > Can you submit a test please, also?
I'm not quite sure what you want the test to be: the procedure `submodules' is not exported by `(ice-9 session)', and there's no test suite for the latter, so testing this change properly would mean creating such a test suite, checking all directly affected exported procedures. Those are `apropos-fold-exported' and `apropos-fold-accessible'. Testing them is a bit involved, due to the cycles in the module tree that we have discussed in the past, and that imply that any fold that does not keep track of visited modules and escapes somehow upon detecting a cycle, will enter an infinite loop. Even when escaping, one's not guaranteed to visit all modules. IIRC, those cycles cannot be eliminated for backwards compatibility reasons. IMHO, given the cycles, the apropos-fold* functions are broken (one cannot fold over cyclic structures), and maybe should be fixed instead of applying only this partial fix. A possible solution is making apropos-fold-* work on a real DAG, by prunning cycles during the traversal. IIRC, the modules causing cycles where among those having gensym's as names: if they were catchable by a predicate somehow, and easy solution would be to filter them out in `submodules' -- if for some reason a user needs a gensym module (i don't know what they are or whether they're part of the public module interface), she can access it via `module-submodules'. jao