honestly, classes are bad.
-
-
at least a trait will tell you if your struct isn't compatible as the interface changes.
-
But sure, a massive stack of inheritance could be just as messy as a writhing mass of composed traits in some respects. Requires readers to research stuff all over to get a solid understanding of the type.
-
Generally, I'd favor a trait pile in the long run since each has their own limited view of the object. Far less cognitive contention that way.
-
Honestly, absolutely everything is probably bad if used to excess. I find classes useful sometimes
-
I tend to act out like this while wading through large legacy codebases, so pay me no mind. It does seem like class trees are a devilishly attractive footgun in many cases I've seen lately. Very difficult to build a mental model around systems written by others.
-
Agree on that last point. Code by others—that should definitely be avoided ;-).
-
It's interesting. We're updating portions of a large monorepo to be packages, meanwhile we're updating all the symbols from camel to snake case. Integrating the new version into the rest of the mono means doing lots of by-eye escape analysis.
-
every time one of the objects is returned from these apis is returned from a function or attached to a class attribute, I have to put on a sweat suit and go jogging to chase it.
End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.