/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/index.py

merge bzr.dev r3564

Show diffs side-by-side

added added

removed removed

Lines of Context:
219
219
            raise errors.BzrError('Failed index creation. Internal error:'
220
220
                ' mismatched output length and expected length: %d %d' %
221
221
                (len(result.getvalue()), expected_bytes))
222
 
        return StringIO(''.join(lines))
 
222
        return result
223
223
 
224
224
 
225
225
class GraphIndex(object):
284
284
    def __ne__(self, other):
285
285
        return not self.__eq__(other)
286
286
 
 
287
    def __repr__(self):
 
288
        return "%s(%r)" % (self.__class__.__name__,
 
289
            self._transport.abspath(self._name))
 
290
 
287
291
    def _buffer_all(self):
288
292
        """Buffer all the index data.
289
293
 
877
881
            elements = line.split('\0')
878
882
            if len(elements) != self._expected_elements:
879
883
                raise errors.BadIndexData(self)
880
 
            # keys are tuples
881
 
            key = tuple(elements[:self._key_length])
 
884
            # keys are tuples. Each element is a string that may occur many
 
885
            # times, so we intern them to save space. AB, RC, 200807
 
886
            key = tuple(intern(element) for element in elements[:self._key_length])
882
887
            if first_key is None:
883
888
                first_key = key
884
889
            absent, references, value = elements[-3:]