factoring out computation of predecessors into distinct subclass