Comment on Ask HN: Functions: how long is too long?Comments−jacquesm16yToo long is when you need more than once sentence to describe what a function does or when the function name gets too long.That's a pretty good indicator because it shows that you could 'abstract' something out and make it an individual routine.Err on the side of caution, better to have smaller functions than larger ones, unless you have a very good reason not to.And if performance is your worry and you work in 'C' then inline is your friend.
Comments
Too long is when you need more than once sentence to describe what a function does or when the function name gets too long.
That's a pretty good indicator because it shows that you could 'abstract' something out and make it an individual routine.
Err on the side of caution, better to have smaller functions than larger ones, unless you have a very good reason not to.
And if performance is your worry and you work in 'C' then inline is your friend.