Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #50150
| From | Dave Angel <davea@davea.name> |
|---|---|
| Subject | Re: A small question about PEP 8 |
| Date | 2013-07-08 08:33 -0400 |
| References | <CAAF+z6Hp=TZJwcDgyT94cv6Mx3Gy4gxSiZ640b9voAAjgsi6dw@mail.gmail.com> <mailman.4380.1373280314.3114.python-list@python.org> <51daaa51$0$9505$c3e8da3$5496439d@news.astraweb.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.4383.1373286831.3114.python-list@python.org> (permalink) |
On 07/08/2013 08:02 AM, Steven D'Aprano wrote:
> On Mon, 08 Jul 2013 11:39:21 +0100, Joshua Landau wrote:
>
<SNIP>
>
>> Or you can (be sane) and put it at no indentation:
>>
>> """
>> a_wonderful_set_of_things = {
>> ...,
>> not_missing_an_end_brace
>> }
>> """
>
> I consider that the least aesthetically pleasing, and also rather awkward:
>
>
> some_result = some_function(
> arg1, arg2, arg3, arg4,
> [item1, item2, item3, item4,
> item5, item6, item7,
> item8, item9, item10,
> ],
> arg6, key=spam, word=eggs,
> extras=None, foo=bar,
> )
or even better:
class MyClass:
def my_method(self):
if self.flag:
self.value.append(
arg1,
arg2,
arg3
)
return self.value
--
DaveA
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: A small question about PEP 8 Joshua Landau <joshua.landau.ws@gmail.com> - 2013-07-08 11:39 +0100
Re: A small question about PEP 8 Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-07-08 12:02 +0000
Re: A small question about PEP 8 Dave Angel <davea@davea.name> - 2013-07-08 08:33 -0400
Re: A small question about PEP 8 Joshua Landau <joshua.landau.ws@gmail.com> - 2013-07-08 14:07 +0100
csiph-web