Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.033 X-Spam-Evidence: '*H*': 0.93; '*S*': 0.00; 'context': 0.07; 'broke': 0.09; 'lines.': 0.09; 'snippet': 0.09; 'cc:addr:python-list': 0.11; 'indent': 0.16; 'semantically': 0.16; 'somewhere.': 0.16; 'worse.': 0.16; '\xc2\xa0i': 0.16; 'sender:addr:gmail.com': 0.17; 'wrote:': 0.18; '>>>': 0.22; 'code,': 0.22; 'cc:addr:python.org': 0.22; 'install': 0.23; 'cc:2**0': 0.24; 'first,': 0.26; 'least': 0.26; 'header:In-Reply-To:1': 0.27; 'tried': 0.27; 'feature': 0.29; 'message-id:@mail.gmail.com': 0.30; "i'm": 0.30; '(which': 0.31; 'program,': 0.31; 'code': 0.31; 'lines': 0.31; 'that.': 0.31; '(although': 0.31; '+0100,': 0.31; 'clever': 0.31; 'indentation': 0.31; 'quite': 0.32; 'not.': 0.33; 'moment': 0.34; 'screen': 0.34; 'maybe': 0.34; "i'd": 0.34; 'editor': 0.35; 'but': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'should': 0.36; 'skip:& 10': 0.38; 'mine': 0.38; 'work?': 0.38; 'skip:& 20': 0.39; 'does': 0.39; "couldn't": 0.39; 'extremely': 0.39; 'either': 0.39; 'how': 0.40; 'even': 0.60; 'truly': 0.60; 'july': 0.63; '8bit%:10': 0.64; 'minutes': 0.67; 'between': 0.67; 'jul': 0.74; 'flipping': 0.84; 'serious': 0.97; '2013': 0.98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=CY2Q5MoP0K6zvvGjrzSCdtHaXGEn8U7ssSoxVi2Zx04=; b=y6ZL0qaa5/+vcQ0CWOAyC4kLXEfRNkpBSj97wYeMm8otcWW0FnPnXjLX9/fEkr4k9p NdGs4fGPRwyoC/gBG7trKwfs90uuqBrHtpYJMP6nGolfzX87m7aCzY+NmCC3Cr2aG1lr L131mbshi23vhusgqtakobzvewTJHBHIvXWZMfYaSl8FDH6OxvhiVhGoA4Ex5tgSdRyW WErEekehOYpai51eZyyVN4LshMH6DUgIvMqL4y8r/TTEIP+ydW4UyfM4pxnNKVgm2nGG oC42SAZJdFr2XO/WYnrGLvZT4zpWQVa4n81xYHyW4spHn5IDhWZlRcK7a1NluBSueaDB DP0Q== X-Received: by 10.152.42.171 with SMTP id p11mr27693648lal.79.1375150389573; Mon, 29 Jul 2013 19:13:09 -0700 (PDT) MIME-Version: 1.0 Sender: joshua.landau.ws@gmail.com In-Reply-To: References: <51f6d9f6$0$30000$c3e8da3$5496439d@news.astraweb.com> From: Joshua Landau Date: Tue, 30 Jul 2013 03:12:29 +0100 X-Google-Sender-Auth: czOfiACUEUhcAHW5_tXJtryXl4s Subject: Re: PEP8 79 char max To: Rhodri James Content-Type: multipart/alternative; boundary=001a11c356567bbb9904e2b126d5 Cc: python-list X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 116 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1375150398 news.xs4all.nl 15879 [2001:888:2000:d::a6]:34770 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:51538 --001a11c356567bbb9904e2b126d5 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 30 July 2013 01:41, Rhodri James wrote: > On Tue, 30 Jul 2013 01:11:18 +0100, Joshua Landau > wrote: > > On 30 July 2013 00:08, Rhodri James wrote: >> >>> I'm working on some shonky C code at the moment that inconsistent >>> indentation and very long lines. It is extremely annoying not to be >>> able to put the original code, my "translation" and sundry utilities >>> all side-by-side on the same screen (and it's not a particularly >>> small screen), and having to keep flipping between them slows me >>> down dramatically. Long lines have no effect on the speed of the >>> program, but they can have serious effects on the speed of the >>> programmer. >>> >> >> Then just wrap it. This is a very automatable thing for editors. There >> might even be a clever hard-wrap somewhere. I just tried pyformat -- tha= t >> works wonders. >> > > I tried that at first, but it actually made matters worse. "Simple" > word-wrapping just broke the structural cues from indentation (which I'd > already had to instruct my editor to make at least somewhat consistent). = I > couldn't just take in the code layout at a glance, I had to work at it. 1) pyformat's quite sane, maybe you should try that. It's a few minutes wasted at worst. (sudo pip install pyformat; pyformat [-i for inplace changes]) 2) How does your soft word-wrap work? I know some editors do it terribly, mine does it passably=C2=B9. I don't know any that do it truly semantically (although it's a feature worthy of implementation). 3) Is the code secret? Let's see a "difficult" snippet if not. =C2=B9 It either indents to the same indentation as the line's start or an = extra indent inwards, depending on context --001a11c356567bbb9904e2b126d5 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On 30 July 2013 01:41, Rhodri James <= rhodri@wil= debst.demon.co.uk> wrote:
On Tue, 30 Jul 2013 01:11:18 +0100, Joshua Landau <= ;joshua@landau.ws= > wrote:

On 30 July 2013 00:08, Rhodri James <rhodri@wildebst.demon.co.uk> wrote:
I'm working on some shonky C code at the moment that inconsistent
indentation and very long lines. =C2=A0It is extremely annoying not to be a= ble to put the original code, my "translation" and sundry utiliti= es
all side-by-side on the same screen (and it's not a particularly
small screen), and having to keep flipping between them slows me
down dramatically. =C2=A0 Long lines have no effect on the speed of the
program, but they can have serious effects on the speed of the
programmer.

Then just wrap it. This is a very automatable thing for editors. There
might even be a clever hard-wrap somewhere. I just tried pyformat -- that works wonders.

I tried that at first, but it actually made matters worse. =C2=A0"Simp= le" word-wrapping just broke the structural cues from indentation (whi= ch I'd already had to instruct my editor to make at least somewhat cons= istent). =C2=A0I couldn't just take in the code layout at a glance, I h= ad to work at it.

1) pyformat's quite sane, maybe you should try that= . It's a few minutes wasted at worst. (sudo pip install pyformat; pyfor= mat <infile> [-i for inplace changes])

2) How does your soft word-wrap work? I know some editors do it terribly, m= ine does it passably=C2=B9. I don't know any that do it truly semantica= lly (although it's a feature worthy of implementation).

3) Is the code secret? Let's see a "difficult&= quot; snippet if not.

=C2=B9 It either indents to = the same indentation as the line's start or an extra indent inwards, de= pending on context
--001a11c356567bbb9904e2b126d5--