sl/cont_shape_seq: factorize out collectShapeSequencesCore()
sl/cont_shape_seq: break infinite loop in collectShapeSequences()
sl/symtrace: fix over-sensitive loop prevention in resolveIdMapping()