summaryrefslogtreecommitdiffstats
path: root/Doc/glossary.rst
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2010-10-06 08:13:26 (GMT)
committerGeorg Brandl <georg@python.org>2010-10-06 08:13:26 (GMT)
commit914a218fbe6d970059b4683d73a449cbc6cf5bf3 (patch)
tree70676b3283f96aff14ffc7aebdaf11a5d254f36f /Doc/glossary.rst
parentc7b6908bb1fbdbc5f36eb55fb423cab179ab4069 (diff)
downloadcpython-914a218fbe6d970059b4683d73a449cbc6cf5bf3.zip
cpython-914a218fbe6d970059b4683d73a449cbc6cf5bf3.tar.gz
cpython-914a218fbe6d970059b4683d73a449cbc6cf5bf3.tar.bz2
Merged revisions 82629,82632,82724,82757-82758,82760-82763,82798-82799,82801 via svnmerge from
svn+ssh://svn.python.org/python/branches/py3k ........ r82629 | georg.brandl | 2010-07-07 20:51:43 +0200 (Mi, 07 Jul 2010) | 1 line Make comment out of an awkward note. ........ r82632 | georg.brandl | 2010-07-07 21:04:36 +0200 (Mi, 07 Jul 2010) | 1 line Turn more notes into comments. ........ r82724 | georg.brandl | 2010-07-09 09:33:15 +0200 (Fr, 09 Jul 2010) | 1 line 2.7 is now stable. ........ r82757 | georg.brandl | 2010-07-10 10:58:37 +0200 (Sa, 10 Jul 2010) | 1 line Fix markup. ........ r82758 | georg.brandl | 2010-07-10 12:23:40 +0200 (Sa, 10 Jul 2010) | 1 line Emphasize role of count for Pascal string. ........ r82760 | georg.brandl | 2010-07-10 12:39:57 +0200 (Sa, 10 Jul 2010) | 1 line #3214: improve description of duck-typing in glossary. ........ r82761 | georg.brandl | 2010-07-10 13:40:13 +0200 (Sa, 10 Jul 2010) | 1 line #1434090: properly append child in expatbuilder doctype handler. ........ r82762 | georg.brandl | 2010-07-10 13:51:06 +0200 (Sa, 10 Jul 2010) | 1 line #8338: fix outdated class name. ........ r82763 | georg.brandl | 2010-07-10 14:01:34 +0200 (Sa, 10 Jul 2010) | 1 line #8456: fix signature of sqlite3.connect(). ........ r82798 | georg.brandl | 2010-07-11 11:23:11 +0200 (So, 11 Jul 2010) | 1 line #6774: explain shutdown() behavior varying with platform. ........ r82799 | georg.brandl | 2010-07-11 11:26:57 +0200 (So, 11 Jul 2010) | 1 line Fix typo. ........ r82801 | georg.brandl | 2010-07-11 11:33:39 +0200 (So, 11 Jul 2010) | 1 line #9184: fix default value for "buffering" param of open(). ........
Diffstat (limited to 'Doc/glossary.rst')
-rw-r--r--Doc/glossary.rst6
1 files changed, 3 insertions, 3 deletions
diff --git a/Doc/glossary.rst b/Doc/glossary.rst
index cc7b28e..8dea228 100644
--- a/Doc/glossary.rst
+++ b/Doc/glossary.rst
@@ -150,9 +150,9 @@ Glossary
object.
duck-typing
- A pythonic programming style which determines an object's type by inspection
- of its method or attribute signature rather than by explicit relationship
- to some type object ("If it looks like a duck and quacks like a duck, it
+ A programming style which does not look at an object's type to determine
+ if it has the right interface; instead, the method or attribute is simply
+ called or used ("If it looks like a duck and quacks like a duck, it
must be a duck.") By emphasizing interfaces rather than specific types,
well-designed code improves its flexibility by allowing polymorphic
substitution. Duck-typing avoids tests using :func:`type` or