The recursion on line 201 is necessary. Suppose if you have info on specific edges, you ask for info on part->inEdgeFromAny, getLattice_ex will return NULL on line 199. Calling getLattice_ex on line 201 instead would still return NULL. Now,  recursing on the same function will invoke meetLatticeInfo on line 210.