Skip to main content
3 events
when toggle format what by license comment
Mar 29, 2019 at 18:37 comment added WillD Moving from multiple returns to setting the return value in multiple places doesn't eliminate cyclomatic complexity, it only unifies the exit location. All the problems which cyclomatic complexity can indicate in the given context remain. "It's harder to debug since the logic needs to be carefully studied in conjunction with the conditional statements to understand what caused the returned value" Again, the logic doesn't change by unifying the return. If you have to carefully study code to understand how it works, it needs to be refactored, full stop.
S Oct 8, 2018 at 11:33 history answered Sorter CC BY-SA 4.0
S Oct 8, 2018 at 11:33 history made wiki Post Made Community Wiki by Sorter