comparison doc/v2_planning/coding_style.txt @ 1075:d422f726c156

coding_style: Discussion and one more point to think about
author Olivier Delalleau <delallea@iro>
date Fri, 10 Sep 2010 11:42:48 -0400
parents ee7f34fc98fe
children 56c5f0990869
comparison
equal deleted inserted replaced
1074:ee7f34fc98fe 1075:d422f726c156
95 a, b, c, d, e, f) 95 a, b, c, d, e, f)
96 --> Probably depends on the specific situation, but we could have a 96 --> Probably depends on the specific situation, but we could have a
97 few typical examples (and the same happens with multi-lines lists) 97 few typical examples (and the same happens with multi-lines lists)
98 (Fred: I would do 2 or 3, but not 1. I find it more redable when the 98 (Fred: I would do 2 or 3, but not 1. I find it more redable when the
99 indent is broken after a paranthesis then at any point. 99 indent is broken after a paranthesis then at any point.
100 OD: After thinking about it, I agreee as well. My recommendation would
101 be to go with 2 when it can fit on two lines, and 3 otherwise. Same
102 with lists.
100 103
101 * From PEP 257: The BDFL [3] recommends inserting a blank line between the 104 * From PEP 257: The BDFL [3] recommends inserting a blank line between the
102 last paragraph in a multi-line docstring and its closing quotes, placing 105 last paragraph in a multi-line docstring and its closing quotes, placing
103 the closing quotes on a line by themselves. This way, Emacs' 106 the closing quotes on a line by themselves. This way, Emacs'
104 fill-paragraph command can be used on it. 107 fill-paragraph command can be used on it.
285 288
286 * Always raise exception with 289 * Always raise exception with
287 raise MyException(args) 290 raise MyException(args)
288 where MyException inherits from Exception. 291 where MyException inherits from Exception.
289 292
293 Mercurial commits
294 -----------------
295
296 * How to write good commit messages?
297 * Standardize the merge commit text (what is the message from fetch?)
298