On Monday, 20 July 2015 at 19:44:01 UTC, John Colvin wrote:
On Monday, 20 July 2015 at 18:17:18 UTC, Adam D. Ruppe wrote:
Quick, what does this loop in this function do?

void PanelBar::RepositionExpandedPanels(Panel* fixed_panel)

I'm willing to guess it repositions the expanded panels.... named functions are the best abstraction.

That's great for an API user, but it's not as massively impactful for actually getting the code right, changing the code, finding the bugs in the code, etc... where you need to actually need to understand the logic.

P.s. which is not to say that sensibly breaking code in to functions with good names doesn't help with the above, but just that it doesn't cover all of the same problems that e.g. ranges/algorithms try to address.

Reply via email to