summaryrefslogtreecommitdiff
path: root/git/diff.py
diff options
context:
space:
mode:
authorYobmod <yobmod@gmail.com>2021-07-19 19:10:45 +0100
committerYobmod <yobmod@gmail.com>2021-07-19 19:10:45 +0100
commit9e5e969479ec6018e1ba06b95bcdefca5b0082a4 (patch)
tree574e03c6c4acd1067e3b285974651ec9e9529a49 /git/diff.py
parent9a587e14d509cc77bf47b9591d1def3e5a1df570 (diff)
downloadgitpython-9e5e969479ec6018e1ba06b95bcdefca5b0082a4.tar.gz
Change remaining type comments to py3.6+ types
Diffstat (limited to 'git/diff.py')
-rw-r--r--git/diff.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/git/diff.py b/git/diff.py
index f8c0c25f..98a5cfd9 100644
--- a/git/diff.py
+++ b/git/diff.py
@@ -351,13 +351,13 @@ class Diff(object):
return hash(tuple(getattr(self, n) for n in self.__slots__))
def __str__(self) -> str:
- h = "%s" # type: str
+ h: str = "%s"
if self.a_blob:
h %= self.a_blob.path
elif self.b_blob:
h %= self.b_blob.path
- msg = '' # type: str
+ msg: str = ''
line = None # temp line
line_length = 0 # line length
for b, n in zip((self.a_blob, self.b_blob), ('lhs', 'rhs')):
@@ -449,7 +449,7 @@ class Diff(object):
:return: git.DiffIndex """
## FIXME: Here SLURPING raw, need to re-phrase header-regexes linewise.
- text_list = [] # type: List[bytes]
+ text_list: List[bytes] = []
handle_process_output(proc, text_list.append, None, finalize_process, decode_streams=False)
# for now, we have to bake the stream