Kiln » Dependencies » Dulwich Read More
Clone URL:  
Pushed to one repository · View In Graph Contained in master

Replace :yield: with :return: as the former is not standard rest.

Changeset d5d870c33397

Parent d3eebff93eb4

by Jelmer Vernooij

Changes to 2 files · Browse files at d5d870c33397 Showing diff from parent d3eebff93eb4 Diff from another changeset...

 
122
123
124
125
126
127
128
 
 
 
 
 
129
130
131
 
159
160
161
162
163
 
 
164
165
166
 
122
123
124
 
 
 
 
125
126
127
128
129
130
131
132
 
160
161
162
 
 
163
164
165
166
167
@@ -122,10 +122,11 @@
  :param tree1_id: The SHA of the first Tree object to iterate, or None.   :param tree2_id: The SHA of the second Tree object to iterate, or None.   :param prune_identical: If True, identical subtrees will not be walked. - :yield: Pairs of TreeEntry objects for each pair of entries in the trees and - their subtrees recursively. If an entry exists in one tree but not the - other, the other entry will have all attributes set to None. If neither - entry's path is None, they are guaranteed to match. + :return: Iterator over Pairs of TreeEntry objects for each pair of entries + in the trees and their subtrees recursively. If an entry exists in one + tree but not the other, the other entry will have all attributes set + to None. If neither entry's path is None, they are guaranteed to + match.   """   # This could be fairly easily generalized to >2 trees if we find a use case.   mode1 = tree1_id and stat.S_IFDIR or None @@ -159,8 +160,8 @@
  :param tree2_id: The SHA of the target tree.   :param want_unchanged: If True, include TreeChanges for unmodified entries   as well. - :yield: TreeChange instances for each change between the source and target - tree. + :return: Iterator over TreeChange instances for each change between the + source and target tree.   """   entries = walk_trees(store, tree1_id, tree2_id,   prune_identical=(not want_unchanged))
 
149
150
151
152
 
 
153
154
155
 
149
150
151
 
152
153
154
155
156
@@ -149,7 +149,8 @@
    :param tree_id: SHA1 of the tree.   :param include_trees: If True, include tree objects in the iteration. - :yield: TreeEntry namedtuples for all the objects in a tree. + :return: Iterator over TreeEntry namedtuples for all the objects in a + tree.   """   for entry, _ in walk_trees(self, tree_id, None):   if not stat.S_ISDIR(entry.mode) or include_trees: