def _add_hash(self, hashes, item_hash, item, i): if item_hash in hashes: hashes[item_hash].indexes.append(i) else: hashes[item_hash] = IndexedHash(indexes=[i], item=item)
def add_hash(hashes, item_hash, item, i): if item_hash in hashes: hashes[item_hash].indexes.append(i) else: hashes[item_hash] = IndexedHash([i], item)