Live data from Hacker News

All evidence points to OOP being bullshit (2013)

blog.pivotal.io

31–40 of 126 posts

Re: All evidence points to OOP being bullshit (2013)

#31

> Probably as good as any other programming paradigma out there. I take offence with postmodern relativism. Not every paradigm is created equal (and for the record, black culture is less "good" than white culture. Come on, "acting white" because you have good grades?). The way to get better as a professional is to analyze various ways of doing stuff and find which is better and how much of it you can use. This articl…

Jesus christ you really destroyed any chance anyone had of taking your point seriously by just throwing in some racism.

Re: All evidence points to OOP being bullshit (2013)

#32
I appreciate there's something I'm missing, but:

I use closures to hold state all the time in node, I still don't understand why state in a closure is better than state in an object.

If someone could explain this I'd be grateful: articles like this just seem to say 'state is bad' and ignore that it still exists in functional scopes.

Re: All evidence points to OOP being bullshit (2013)

#34
Compare the DirectX XNA OOP library to the OpenGL procedural library, and you will quickly see that when OOP is done right it makes code fun and easy to work with again.

In my my mind OOP is the next logical step after procedural programming (simply packaging up a set of procedures into an object, and adding a few new ideas like inheritance and so on). Functional programming though is not the next logical step; it is a total paradigm shift. The main argument is that you get rid of state etc which means you can parallelize better - but why are no cutting edge games made in an FP language I wonder? Surely they would want to distribute all the physics collision rendering and so on to multiple cores?

It's because functional programming as a separate language makes no sense, you lose too much. But incorporating FP style into OOP languages (such as with the new C++ constexpr, C# linq, and Java lambda), and giving the programmer the choice to use it when it makes sense is a far more powerful option.

Re: All evidence points to OOP being bullshit (2013)

#35

Does anybody know of any language that supports OO, but that lets you declare pure functions/methods - enforcing that those pure functions/methods only use other pure functions, don't use global objects, etc? Lately we're adopting Redux [1] together with React and the idea of being able to mix functional and OO in a better way looks more and more interesting to me. [1] https://github.com/rackt/redux

Don't you need both in a language that supports both? I use a language that offers both but I only use methods.

Re: All evidence points to OOP being bullshit (2013)

#36

Depends on how you use it, of course. Libraries make wonderful showcases for OOP strengths - I always like to give Java Collections as an example. But if you actually build your application code as OOP... well, I might privately think you deserve everything that happens to you because of that. I think education carries most of the guilt for this. The typical examples given in OOS classes are stuff like Car is an ance…

> But if you actually build your application code as OOP > Beans and Entreprise Java I don't know. Netflix is built on Java, using OOP. It works well for them. Windows is built on OOP, quite a big application and works. J2EE has its problems, but it also gives you a lot of functionality. Reusing methods is nice, but developers on projects with very complex business rules (does not equal simple, but large scale projec…

> J2EE has its problems, but it also gives you a lot of functionality

I did have that in the back of my head when I wrote the comment. And speaking of, I'm also aware that OOP was very popular, and I don't feel completely comfortable when I criticize successful stuff - it must have worked for a reason. But still, that's as far as my brain can take me by itself: OOP should be used sparingly and EJB should not exist.

(For the record I code mostly in Java, though as lisp-like as I can)

Re: All evidence points to OOP being bullshit (2013)

#37
post #5

> Extremist languages like Java force you to think of everything in terms of objects. Erm, Java is by far not the most OO programming language there is. For example, primitive types are not objects (no, auto-boxing doesn't make them objects). > But is Object Orientation (OO) a good idea? Probably as good as any other programming paradigma out there. > Does it have problems? Sure, like every other language as well. >…

I think Java can be classified as an "extremist OOP" language because it doesn't really support self-standing functions.

Re: All evidence points to OOP being bullshit (2013)

#39
post #5

> Extremist languages like Java force you to think of everything in terms of objects. Erm, Java is by far not the most OO programming language there is. For example, primitive types are not objects (no, auto-boxing doesn't make them objects). > But is Object Orientation (OO) a good idea? Probably as good as any other programming paradigma out there. > Does it have problems? Sure, like every other language as well. >…

My sentiments exactly, kinda surprised this title made it so high up!

OOP has some fantastic applications and may have been oversold to the author for a project he worked on. OOP(s)!

Re: All evidence points to OOP being bullshit (2013)

#40
post #30

[Shameless plug] For a philosophical interpretation on the differences between OOP and FP, you may enjoy my gist: Descartes, Berkeley and Functional Reactive Programming https://gist.github.com/dmvaldman/f957dd9a8ed3f6edf35d

It's actually a common misquote of Descartes to say "I think therefore I am." A more proper translation is "I think, I am" which has significant implications for his philosophy.

As I understand it, this isn't a misquote/mistranslation at all. He said "I think, I am" and "I think therefore I am" in different works exploring the same topics, without a lot of distinction between them.
Post reply on HN