Re:Erlangers, Use Labels
by andybak on Thursday December 08, 2016 @05:01AM
(#13129413)
Would I be correct in thinking this is a similar argument those put forward by GvR against the desirability of multi-line lambdas in Python? i.e. once you need multiple lines then you probably should be naming them.
[ Parent
| on HN ]
Yes. There's no pride in jamming the most amount of code into one line unless you're entering a contest.
Re:Erlangers, Use Labels
by chriswarbo on Thursday December 08, 2016 @05:24AM
(#13129488)
Surely it's the current one-line* restriction which forces "jamming the most amount of code into one line".
Allowing multiple lines, by definition, allows breaking up those lines.
* It's not actually one-line, it's one expression; Python's just picky about where you're allowed to break up an expression over multiple lines. For example see http://softwareengineering.stackexchange.com/questions/99243...
Re:Erlangers, Use Labels
by randallsquared on Thursday December 08, 2016 @09:02AM
(#13130278)
I don't think GP meant one editor line, but one "line of code".
Heh, I remember being kind of scolded for using anything but "isolated functions" in MVC courses.