~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/delta.py

  • Committer: Martin Pool
  • Date: 2005-09-22 07:04:14 UTC
  • Revision ID: mbp@sourcefrog.net-20050922070414-06a503a1d47b5ce4
- avoid converting inventories to/from StringIO 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#! /usr/bin/env python
1
2
# -*- coding: UTF-8 -*-
2
3
 
3
4
# This program is free software; you can redistribute it and/or modify
68
69
            self.modified, self.unchanged)
69
70
 
70
71
    def has_changed(self):
71
 
        changes = len(self.added) + len(self.removed) + len(self.renamed)
72
 
        changes += len(self.modified) 
73
 
        return (changes != 0)
 
72
        return bool(self.modified
 
73
                    or self.added
 
74
                    or self.removed
 
75
                    or self.renamed)
74
76
 
75
77
    def touches_file_id(self, file_id):
76
78
        """Return True if file_id is modified by this delta."""