Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #65784
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!xlned.com!feeder7.xlned.com!newsfeed.xs4all.nl!newsfeed4a.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <rosuav@gmail.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.014 |
| X-Spam-Evidence | '*H*': 0.98; '*S*': 0.01; 'else:': 0.03; 'operator': 0.03; 'cc:addr:python-list': 0.11; 'python': 0.11; 'def': 0.12; 'be:': 0.16; 'did,': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'wrote:': 0.18; 'feb': 0.22; 'cc:addr:python.org': 0.22; "shouldn't": 0.24; 'mon,': 0.24; 'cc:2**0': 0.24; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; 'class': 0.32; 'could': 0.34; 'no,': 0.35; 'received:google.com': 0.35; 'does': 0.39; 'air': 0.66; 'ethan': 0.84; 'furman': 0.84; 'to:none': 0.92; 'hot': 0.96 |
| DKIM-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=WAJ3hmekdLkt7Xyl852z7JbaXPQOLOynSECQzCaSwas=; b=varr6QTwPALK0mIw+wYCSaiauRq7irZ4kU+LtMHsPWtMB/HD+QP/2e3zkopRCgH4fq FG6bXEPY8Ji9+/2IE17RX+wbxVEPhSMYaKnRVEhpHD1XsDLA9Tzs1RDeP0GAIvnJLB1H mVUye8YE5nRJqaupDO6CuziqLUofoVPpSz29nYs77y+Butvid+ivb+89j3uGS7VNrib9 8XiYe/96VDbK4RY9mm47fxpe5SBqRjRmhNUK3bqBVNIeKLGFN9p1PKjNWW8zvOz3KUUs WoJAwRcWA30fw6+Djdc6ASRx3B6keEnlZW73vSwhZDYgFt28YpazmG+5GMXw2IYtnqRH DQ3A== |
| MIME-Version | 1.0 |
| X-Received | by 10.66.197.135 with SMTP id iu7mr4030400pac.149.1391983965789; Sun, 09 Feb 2014 14:12:45 -0800 (PST) |
| In-Reply-To | <52F7C097.7050407@stoneleaf.us> |
| References | <mailman.6584.1391950328.18130.python-list@python.org> <roy-94D93E.11521509022014@news.panix.com> <52F7C097.7050407@stoneleaf.us> |
| Date | Mon, 10 Feb 2014 09:12:45 +1100 |
| Subject | Re: imperative mood in docstrings |
| From | Chris Angelico <rosuav@gmail.com> |
| Cc | "python-list@python.org" <python-list@python.org> |
| Content-Type | text/plain; charset=UTF-8 |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.15 |
| Precedence | list |
| List-Id | General discussion list for the Python programming language <python-list.python.org> |
| List-Unsubscribe | <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe> |
| List-Archive | <http://mail.python.org/pipermail/python-list/> |
| List-Post | <mailto:python-list@python.org> |
| List-Help | <mailto:python-list-request@python.org?subject=help> |
| List-Subscribe | <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.6604.1391983969.18130.python-list@python.org> (permalink) |
| Lines | 23 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1391983969 news.xs4all.nl 2950 [2001:888:2000:d::a6]:49828 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:65784 |
Show key headers only | View raw
On Mon, Feb 10, 2014 at 4:53 AM, Ethan Furman <ethan@stoneleaf.us> wrote: > Shouldn't that be: > > class Pig: > def fly(self): > "Soar gracefully through the air if a hot place is very cold." > if hell is frozen: > self.sprout_wings() > self.altitude += 10 > self.velocity += 25 > else: > self.splat() > > ;) The Python 'is' operator does not do what you think it does. If it did, 'hell is frozen' would mean that one could say 'war is frozen', which makes no sense. No, I think this calls for a LISP-style predicate: if frozenp(hell): ChrisA
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
imperative mood in docstrings bagrat lazaryan <bagratte@live.com> - 2014-02-09 16:05 +0400
Re: imperative mood in docstrings Roy Smith <roy@panix.com> - 2014-02-09 11:52 -0500
Re: imperative mood in docstrings Chris “Kwpolska” Warrick <kwpolska@gmail.com> - 2014-02-09 18:46 +0100
Re: imperative mood in docstrings Ethan Furman <ethan@stoneleaf.us> - 2014-02-09 09:53 -0800
Re: imperative mood in docstrings Chris Angelico <rosuav@gmail.com> - 2014-02-10 09:12 +1100
Re: imperative mood in docstrings Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-02-09 23:01 +0000
csiph-web