]> granicus.if.org Git - python/commitdiff
Issue #9021: Add an introduction to the copy module. Doc changes suggested by Terry...
authorSenthil Kumaran <senthil@uthcode.com>
Thu, 9 Feb 2012 10:22:01 +0000 (18:22 +0800)
committerSenthil Kumaran <senthil@uthcode.com>
Thu, 9 Feb 2012 10:22:01 +0000 (18:22 +0800)
Doc/library/copy.rst
Misc/NEWS

index b3ce51f57e40dc61ec0d9fdbd666bab2280d1f03..0f23a95398556c6000adf0362fab3399a0c7d10a 100644 (file)
@@ -4,7 +4,11 @@
 .. module:: copy
    :synopsis: Shallow and deep copy operations.
 
-This module provides generic (shallow and deep) copying operations.
+Assignment statements in Python do not copy objects, they create bindings
+between a target and an object. For collections that are mutable or contain
+mutable items, a copy is sometimes needed so one can change one copy without
+changing the other. This module provides generic shallow and deep copy
+operations (explained below).
 
 
 Interface summary:
index fec58eae61706bc3054bc56110dbdcf24eee14a1..e912b49c45301fd9e4c18316df4c51935d1bec5d 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -90,6 +90,8 @@ Core and Builtins
 Library
 -------
 
+- Issue #9021: Add an introduction to the copy module documentation.
+
 - Issue #6005: Examples in the socket library documentation use sendall, where
   relevant, instead send method.