[Python-checkins] cpython (2.7): Removed spaces before colons and semicolons.

serhiy.storchaka python-checkins at python.org
Tue Dec 24 10:08:46 CET 2013


http://hg.python.org/cpython/rev/ee924673d83a
changeset: 88159:ee924673d83a
branch: 2.7
parent: 88150:6aeef7be5752
user: Serhiy Storchaka <storchaka at gmail.com>
date: Tue Dec 24 11:04:06 2013 +0200
summary:
 Removed spaces before colons and semicolons.
files:
 Doc/faq/programming.rst | 2 +-
 Doc/faq/windows.rst | 2 +-
 Doc/howto/logging-cookbook.rst | 1 -
 Doc/howto/urllib2.rst | 6 +++---
 Doc/library/ctypes.rst | 2 +-
 Doc/library/rexec.rst | 2 +-
 Doc/library/simplexmlrpcserver.rst | 2 +-
 Doc/library/telnetlib.rst | 2 +-
 Doc/library/tkinter.rst | 2 +-
 Doc/whatsnew/2.4.rst | 2 +-
 Doc/whatsnew/2.5.rst | 2 +-
 Doc/whatsnew/2.6.rst | 6 +++---
 12 files changed, 15 insertions(+), 16 deletions(-)
diff --git a/Doc/faq/programming.rst b/Doc/faq/programming.rst
--- a/Doc/faq/programming.rst
+++ b/Doc/faq/programming.rst
@@ -910,7 +910,7 @@
 >>> a = array.array('c', s)
 >>> print a
 array('c', 'Hello, world')
- >>> a[0] = 'y' ; print a
+ >>> a[0] = 'y'; print a
 array('c', 'yello, world')
 >>> a.tostring()
 'yello, world'
diff --git a/Doc/faq/windows.rst b/Doc/faq/windows.rst
--- a/Doc/faq/windows.rst
+++ b/Doc/faq/windows.rst
@@ -243,7 +243,7 @@
 ...
 Py_Initialize(); // Initialize Python.
 initmyAppc(); // Initialize (import) the helper class.
- PyRun_SimpleString("import myApp") ; // Import the shadow class.
+ PyRun_SimpleString("import myApp"); // Import the shadow class.
 
 5. There are two problems with Python's C API which will become apparent if you
 use a compiler other than MSVC, the compiler used to build pythonNN.dll.
diff --git a/Doc/howto/logging-cookbook.rst b/Doc/howto/logging-cookbook.rst
--- a/Doc/howto/logging-cookbook.rst
+++ b/Doc/howto/logging-cookbook.rst
@@ -834,4 +834,3 @@
 
 Note that the order of items might be different according to the version of
 Python used.
-
diff --git a/Doc/howto/urllib2.rst b/Doc/howto/urllib2.rst
--- a/Doc/howto/urllib2.rst
+++ b/Doc/howto/urllib2.rst
@@ -18,7 +18,7 @@
 .. sidebar:: Related Articles
 
 You may also find useful the following article on fetching web resources
- with Python :
+ with Python:
 
 * `Basic Authentication <http://www.voidspace.org.uk/python/articles/authentication.shtml>`_
 
@@ -439,7 +439,7 @@
 
 When authentication is required, the server sends a header (as well as the 401
 error code) requesting authentication. This specifies the authentication scheme
-and a 'realm'. The header looks like : ``WWW-Authenticate: SCHEME
+and a 'realm'. The header looks like: ``WWW-Authenticate: SCHEME
 realm="REALM"``.
 
 e.g. ::
@@ -511,7 +511,7 @@
 setting is detected. Normally that's a good thing, but there are occasions
 when it may not be helpful [#]_. One way to do this is to setup our own
 ``ProxyHandler``, with no proxies defined. This is done using similar steps to
-setting up a `Basic Authentication`_ handler : ::
+setting up a `Basic Authentication`_ handler: ::
 
 >>> proxy_support = urllib2.ProxyHandler({})
 >>> opener = urllib2.build_opener(proxy_support)
diff --git a/Doc/library/ctypes.rst b/Doc/library/ctypes.rst
--- a/Doc/library/ctypes.rst
+++ b/Doc/library/ctypes.rst
@@ -215,7 +215,7 @@
 Fundamental data types
 ^^^^^^^^^^^^^^^^^^^^^^
 
-:mod:`ctypes` defines a number of primitive C compatible data types :
+:mod:`ctypes` defines a number of primitive C compatible data types:
 
 +----------------------+------------------------------------------+----------------------------+
 | ctypes type | C type | Python type |
diff --git a/Doc/library/rexec.rst b/Doc/library/rexec.rst
--- a/Doc/library/rexec.rst
+++ b/Doc/library/rexec.rst
@@ -270,7 +270,7 @@
 if mode in ('r', 'rb'):
 pass
 elif mode in ('w', 'wb', 'a', 'ab'):
- # check filename : must begin with /tmp/
+ # check filename: must begin with /tmp/
 if file[:5]!='/tmp/':
 raise IOError("can't write outside /tmp")
 elif (string.find(file, '/../') >= 0 or
diff --git a/Doc/library/simplexmlrpcserver.rst b/Doc/library/simplexmlrpcserver.rst
--- a/Doc/library/simplexmlrpcserver.rst
+++ b/Doc/library/simplexmlrpcserver.rst
@@ -247,7 +247,7 @@
 Example::
 
 class MyFuncs:
- def div(self, x, y) : return x // y
+ def div(self, x, y): return x // y
 
 
 handler = CGIXMLRPCRequestHandler()
diff --git a/Doc/library/telnetlib.rst b/Doc/library/telnetlib.rst
--- a/Doc/library/telnetlib.rst
+++ b/Doc/library/telnetlib.rst
@@ -208,7 +208,7 @@
 .. method:: Telnet.set_option_negotiation_callback(callback)
 
 Each time a telnet option is read on the input flow, this *callback* (if set) is
- called with the following parameters : callback(telnet socket, command
+ called with the following parameters: callback(telnet socket, command
 (DO/DONT/WILL/WONT), option). No other action is done afterwards by telnetlib.
 
 
diff --git a/Doc/library/tkinter.rst b/Doc/library/tkinter.rst
--- a/Doc/library/tkinter.rst
+++ b/Doc/library/tkinter.rst
@@ -452,7 +452,7 @@
 Example::
 
 >>> print fred.config()
- {'relief' : ('relief', 'relief', 'Relief', 'raised', 'groove')}
+ {'relief': ('relief', 'relief', 'Relief', 'raised', 'groove')}
 
 Of course, the dictionary printed will include all the options available and
 their values. This is meant only as an example.
diff --git a/Doc/whatsnew/2.4.rst b/Doc/whatsnew/2.4.rst
--- a/Doc/whatsnew/2.4.rst
+++ b/Doc/whatsnew/2.4.rst
@@ -846,7 +846,7 @@
 ['A', 'b', 'c', 'D']
 
 Finally, the *reverse* parameter takes a Boolean value. If the value is true,
- the list will be sorted into reverse order. Instead of ``L.sort() ;
+ the list will be sorted into reverse order. Instead of ``L.sort();
 L.reverse()``, you can now write ``L.sort(reverse=True)``.
 
 The results of sorting are now guaranteed to be stable. This means that two
diff --git a/Doc/whatsnew/2.5.rst b/Doc/whatsnew/2.5.rst
--- a/Doc/whatsnew/2.5.rst
+++ b/Doc/whatsnew/2.5.rst
@@ -286,7 +286,7 @@
 :mod:`pkg.string` and look for the standard module; generally you had to look at
 the contents of ``sys.modules``, which is slightly unclean. Holger Krekel's
 :mod:`py.std` package provides a tidier way to perform imports from the standard
-library, ``import py ; py.std.string.join()``, but that package isn't available
+library, ``import py; py.std.string.join()``, but that package isn't available
 on all Python installations.
 
 Reading code which relies on relative imports is also less clear, because a
diff --git a/Doc/whatsnew/2.6.rst b/Doc/whatsnew/2.6.rst
--- a/Doc/whatsnew/2.6.rst
+++ b/Doc/whatsnew/2.6.rst
@@ -1887,7 +1887,7 @@
 >>> dq=deque(maxlen=3)
 >>> dq
 deque([], maxlen=3)
- >>> dq.append(1) ; dq.append(2) ; dq.append(3)
+ >>> dq.append(1); dq.append(2); dq.append(3)
 >>> dq
 deque([1, 2, 3], maxlen=3)
 >>> dq.append(4)
@@ -2779,12 +2779,12 @@
 types. The following example encodes and decodes a dictionary::
 
 >>> import json
- >>> data = {"spam" : "foo", "parrot" : 42}
+ >>> data = {"spam": "foo", "parrot": 42}
 >>> in_json = json.dumps(data) # Encode the data
 >>> in_json
 '{"parrot": 42, "spam": "foo"}'
 >>> json.loads(in_json) # Decode into a Python object
- {"spam" : "foo", "parrot" : 42}
+ {"spam": "foo", "parrot": 42}
 
 It's also possible to write your own decoders and encoders to support
 more types. Pretty-printing of the JSON strings is also supported.
-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /