• @SwingingKoala
    link
    111 months ago

    tldr

    All OO code can be refactored into equivalent non-OO code that’s as easy or more easy to understand.

    Ok, so what. All non-OO code can be refactored into equivalent OO code that’s as easy or more easy to understand.

    💩💩💩

  • @Limeey@lemmy.world
    link
    fedilink
    1
    edit-2
    11 months ago

    I find most criticisms of OO to be disingenuous - this one in particular is a very simple situation that you reduce the line count by like 5 lines. I’m more interested in seeing cases where you can take a complex state management system and convert it to a functional paradigm that improves the readability and comprehension. Like rewrite the discord.py client using a bag of functions technique and tell me it’s just as readable.

    edit: and I should say, I’m not necessary against what you say, but it’s not fair to do simple conversions and say “it’s better!” Maybe it is better but the proof is not in a 15 line example, imo