'Merge `other` ProviderIndex into this one.'

def merge(self, other):

    other = other.copy()
    for pkg in other.providers:
        if (pkg not in self.providers):
            self.providers[pkg] = other.providers[pkg]
            continue
        (spdict, opdict) = (self.providers[pkg], other.providers[pkg])
        for provided_spec in opdict:
            if (provided_spec not in spdict):
                spdict[provided_spec] = opdict[provided_spec]
                continue
            spdict[provided_spec] = spdict[provided_spec].union(opdict[provided_spec])
