':return: An iterator over ``Synset`` objects that are either proper
hypernyms or instance of hypernyms of the synset.'

def _iter_hypernym_lists(self):

    todo = [self]
    seen = set()
    while todo:
        for synset in todo:
            seen.add(synset)
        (yield todo)
        todo = [hypernym for synset in todo for hypernym in (synset.hypernyms() + synset.instance_hypernyms()) if (hypernym not in seen)]
