Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 42b6877

Browse files
committed
Fix restore (difflib.restore() became a generator too).
1 parent 8a9c284 commit 42b6877

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

Tools/scripts/ndiff.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,8 @@ def main(args):
118118

119119
def restore(which):
120120
restored = difflib.restore(sys.stdin.readlines(), which)
121-
sys.stdout.writelines(restored)
121+
for line in restored:
122+
print line,
122123

123124
if __name__ == '__main__':
124125
args = sys.argv[1:]

0 commit comments

Comments
 (0)