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

Skip to content

Commit 3ccb787

Browse files
committed
Merged revisions 64446,64490,64495,64526,64567 via svnmerge from
svn+ssh://[email protected]/python/trunk ........ r64446 | facundo.batista | 2008-06-21 19:43:56 +0200 (Sat, 21 Jun 2008) | 4 lines Fixed issue #2888. Now the behaviour of pprint when working with nested structures follows the common sense (and works like in 2.5 and 3.0). ........ r64490 | thomas.heller | 2008-06-23 21:51:41 +0200 (Mon, 23 Jun 2008) | 1 line Include debug info when assembling win64.asm in a debug build. ........ r64495 | benjamin.peterson | 2008-06-24 04:41:08 +0200 (Tue, 24 Jun 2008) | 1 line minor fix ........ r64526 | mark.dickinson | 2008-06-25 17:29:32 +0200 (Wed, 25 Jun 2008) | 2 lines issue #3199: Fix typo in Mac/Makefile.in ........ r64567 | mark.dickinson | 2008-06-28 00:20:14 +0200 (Sat, 28 Jun 2008) | 3 lines Fix typo in configure.in, and propagate configure.in changes from r64002 to configure and pyconfig.h.in. ........
1 parent b6531d2 commit 3ccb787

4 files changed

Lines changed: 14 additions & 3 deletions

File tree

Doc/library/pprint.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ The :mod:`pprint` module defines one class:
5050
>>> stuff.insert(0, stuff[:])
5151
>>> pp = pprint.PrettyPrinter(indent=4)
5252
>>> pp.pprint(stuff)
53-
[ [ 'spam', 'eggs', 'lumberjack', 'knights', 'ni'],
53+
[ ['spam', 'eggs', 'lumberjack', 'knights', 'ni'],
5454
'spam',
5555
'eggs',
5656
'lumberjack',

Lib/test/test_pprint.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,17 @@ def test_basic_line_wrap(self):
164164
for type in [list, list2]:
165165
self.assertEqual(pprint.pformat(type(o), indent=4), exp)
166166

167+
def test_nested_indentations(self):
168+
o1 = list(range(10))
169+
o2 = dict(first=1, second=2, third=3)
170+
o = [o1, o2]
171+
expected = """\
172+
[ [0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
173+
{ 'first': 1,
174+
'second': 2,
175+
'third': 3}]"""
176+
self.assertEqual(pprint.pformat(o, indent=4, width=42), expected)
177+
167178
def test_sorted_dict(self):
168179
# Starting in Python 2.5, pprint sorts dict displays by key regardless
169180
# of how small the dictionary may be.

Mac/Makefile.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ altinstallunixtools:
112112
$(INSTALL) -d -m $(DIRMODE) "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin" ;\
113113
fi
114114
for fn in python$(VERSION) pythonw$(VERSION) idle$(VERSION) \
115-
pydoc$(VERSION) python$(VERSION)-config) smtpd$(VERSION).py ;\
115+
pydoc$(VERSION) python$(VERSION)-config smtpd$(VERSION).py ;\
116116
do \
117117
ln -fs "$(prefix)/bin/$${fn}" "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin/$${fn}" ;\
118118
done

PCbuild/_ctypes.vcproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -642,7 +642,7 @@
642642
>
643643
<Tool
644644
Name="VCCustomBuildTool"
645-
CommandLine="ml64 /nologo /c /Fo &quot;$(IntDir)\win64.obj&quot; &quot;$(InputPath)&quot;&#x0D;&#x0A;"
645+
CommandLine="ml64 /nologo /c /Zi /Fo &quot;$(IntDir)\win64.obj&quot; &quot;$(InputPath)&quot;&#x0D;&#x0A;"
646646
Outputs="$(IntDir)\win64.obj"
647647
/>
648648
</FileConfiguration>

0 commit comments

Comments
 (0)