Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #7338

Re: how to inherit docstrings?

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!feeder.news-service.com!news.astraweb.com!border5.a.newsrouter.astraweb.com!not-for-mail
From Ben Finney <ben+python@benfinney.id.au>
Newsgroups comp.lang.python
Subject Re: how to inherit docstrings?
References <b5497fa4-b79b-454e-b2e1-9e48642e2d85@glegroupsg2000goo.googlegroups.com>
X-Public-Key-ID 0xAC128405
X-Public-Key-Fingerprint 517C F14B B2F3 98B0 CB35 4855 B8B2 4C06 AC12 8405
X-Public-Key-URL http://www.benfinney.id.au/contact/bfinney-pubkey.asc
X-Post-From Ben Finney <bignose+hates-spam@benfinney.id.au>
Date Fri, 10 Jun 2011 11:42:44 +1000
Message-ID <87aadqwjfv.fsf@benfinney.id.au> (permalink)
User-Agent Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux)
Cancel-Lock sha1:x86TPvyHZIj6IlJ1LtgupV/ZAo0=
MIME-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Transfer-Encoding 8bit
Lines 14
Organization Unlimited download news at news.astraweb.com
NNTP-Posting-Host 65dd4612.news.astraweb.com
X-Trace DXC=Re?>?d[@LSHjEc;hW[JGKHL?0kYOcDh@JW\:Hm@YlDbJZk<HUDOhnH@UGD@iN[Hd?OnNPmhkLl_[M
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:7338

Show key headers only | View raw


Carl Banks <pavlovevidence@gmail.com> writes:

> Presumably, the reason you are overriding a method in a subclass is to
> change its behavior; I'd expect an inherited docstring to be
> inaccurate more often than not.

In which case the onus is on the programmer implementing different
behaviour to also override the docstring.

-- 
 \         “When we pray to God we must be seeking nothing — nothing.” |
  `\                                          —Saint Francis of Assisi |
_o__)                                                                  |
Ben Finney

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: how to inherit docstrings? Carl Banks <pavlovevidence@gmail.com> - 2011-06-09 18:12 -0700
  Re: how to inherit docstrings? Ben Finney <ben+python@benfinney.id.au> - 2011-06-10 11:42 +1000
  Re: how to inherit docstrings? Eric Snow <ericsnowcurrently@gmail.com> - 2011-06-09 20:37 -0600
  Re: how to inherit docstrings? Terry Reedy <tjreedy@udel.edu> - 2011-06-09 23:59 -0400
    Re: how to inherit docstrings? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-06-10 09:48 +0000
  Re: how to inherit docstrings? Eric Snow <ericsnowcurrently@gmail.com> - 2011-06-09 22:41 -0600
  Re: how to inherit docstrings? Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2011-06-10 19:16 +1200

csiph-web