SAP.ancestor was returning length rather than ancestor when w was reachable from v
Factor out the major functionality of the WordNet constructor