[FELIX-4942] Slightly refactor Candidates.populate() to remove the recursion. [FELIX-4942] Populate the dependent map at the same time.