Hacker News new | ask | show | jobs
by vbg 1682 days ago
OO isn’t a disaster.

What we have learned however is that it’s not the only way to do things.

10 years ago the accepted wisdom was that the only way to program was object oriented.

Thankfully there is hopefully a broader acceptance now that other ways of programming such as composed functions are also great ways to program.

Program in whatever style you like, or whatever your team decides on. Be happy and don’t force your religion on others.

1 comments

There are some neat ways to combine the advantages of OOP and FP. Methods calling free functions, helper objects that never leave the scope of one method or function...

I think the mistake of early 90s was to equate OOP with good programming. It's just a tool, it's suitable for some things and not others.

You can take anything too far. I have seen separation of concerns taken too far. There were models and controllers tightly coupled with a big interface, where the separation was not adding anything of value. It's people designing things they way they "ought to be" without really considering the pros and cons given the problem at hand.