Mercurial > hg
comparison mercurial/patch.py @ 26550:72782f60dbc9
extract: directly assign parent to data dictionary
The temporary variables are not adding anything.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Tue, 06 Oct 2015 02:05:56 -0700 |
parents | 1a680ccdb09a |
children | 5b8faea8b509 |
comparison
equal
deleted
inserted
replaced
26549:1a680ccdb09a | 26550:72782f60dbc9 |
---|---|
269 data['user'] = user | 269 data['user'] = user |
270 data['date'] = date | 270 data['date'] = date |
271 data['branch'] = branch | 271 data['branch'] = branch |
272 return data | 272 return data |
273 | 273 |
274 p1 = p2 = None | |
275 if parents: | 274 if parents: |
276 p1 = parents.pop(0) | 275 data['p1'] = parents.pop(0) |
277 if parents: | 276 if parents: |
278 p2 = parents.pop(0) | 277 data['p2'] = parents.pop(0) |
279 | 278 |
280 data['filename'] = tmpname | 279 data['filename'] = tmpname |
281 data['user'] = user | 280 data['user'] = user |
282 data['date'] = date | 281 data['date'] = date |
283 data['branch'] = branch | 282 data['branch'] = branch |
284 data['nodeid'] = nodeid | 283 data['nodeid'] = nodeid |
285 data['p1'] = p1 | |
286 data['p2'] = p2 | |
287 return data | 284 return data |
288 | 285 |
289 class patchmeta(object): | 286 class patchmeta(object): |
290 """Patched file metadata | 287 """Patched file metadata |
291 | 288 |