I got used to short functions so much, than my normal function length in any other language went down a lot too. Now I'd probably refactor anything that doesn't fit on half of a screen (got fairly big monitors though). And that's a good thing - the effect is easier to read and the shorter the code is, the more self-documenting it becomes, because you have to name every sub-process correctly via the function name. Something that would otherwise be a 40 line function with inline comments: "First do this", "then do that", becomes a two-line: do_this(); do_that(); with ~20 lines in each of them. Much much better.
On the other hand, once you get too used to lambdas, you start missing them in other languages. It just felt natural for me at some point to make a C macro (f, arr, type, len) which did something like map on an array of `type` using a function pointer `f`. That didn't go very well with other people who normally read that code...
Comments
Examples I completely agree with.
I got used to short functions so much, than my normal function length in any other language went down a lot too. Now I'd probably refactor anything that doesn't fit on half of a screen (got fairly big monitors though). And that's a good thing - the effect is easier to read and the shorter the code is, the more self-documenting it becomes, because you have to name every sub-process correctly via the function name. Something that would otherwise be a 40 line function with inline comments: "First do this", "then do that", becomes a two-line: do_this(); do_that(); with ~20 lines in each of them. Much much better.
On the other hand, once you get too used to lambdas, you start missing them in other languages. It just felt natural for me at some point to make a C macro (f, arr, type, len) which did something like map on an array of `type` using a function pointer `f`. That didn't go very well with other people who normally read that code...