
Goodbye, Object Oriented Programming - _emacsomancer_
https://medium.com/@cscalfani/goodbye-object-oriented-programming-a59cda4c0e53
======
rhapsodic
It's amazing that so much excellent software has been written over the past
few decades using object oriented programing, yet this guy seems to be utterly
stymied by it.

Maybe OO isn't the problem.

~~~
smt88
I agree excellent software has been written in OO. However, priorities change
as industries, hardware, and programmers themselves change.

I've found that OO is incredibly confusing to some people because there are
many ways to do one thing. That can be a feature to some and a bug to others.

I've also found that OO requires a level of discipline (e.g. SOLID) that's
almost impossible to enforce. I've known companies who essentially have
someone on the team whose full-time job is monitoring the code quality of the
OO code base. I haven't observed the same thing in functional code bases
(though my sample size is smaller).

~~~
rhapsodic
_> I've found that OO is incredibly confusing to some people because there are
many ways to do one thing. That can be a feature to some and a bug to others._

I've encountered such programmers. They're generally just mediocre programmers
who don't put a lot of effort into upping their game. They typically don't
find functional programming any easier.

 _> I've also found that OO requires a level of discipline (e.g. SOLID) that's
almost impossible to enforce._

Enforcing SOLID categorically is a bad idea, period. And I think one of the
worst things about OO is the copious dogma that has grown up around it. In
that sense, you could say it's a victim of its own success.

------
some_account
I liked functional but had issues figuring out how to not have to keep sending
in objects every time I make a method call. Partials only worked for so
much...

~~~
smt88
> _keep sending in objects every time I make a method call_

Classes and objects can actually be good syntactic sugar to solve this same
problem. You can get a lot of the benefit of functional programming by writing
immutable classes without any inheritance. The first argument of any method in
the class is assumed to be the class itself, which is "POJO/POCO" and
immutable -- "this" becomes a read-only keyword.

~~~
some_account
Yeah it seems like a good way to get the best of both worlds :)

