Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

Sure, object-oriented techniques are great and have stuck around for a while. I know only less than a handful of critics of the OO principles.

It seems as though most non-OO designs and architectures are shunned, yet we continue to write a lot of good software in C and solve a lot of data changes via awk/sed and countless other examples. Correct tool for the correct job, yes?

I'm having a hard time finding articles, presentations, or published criticisms of OO (even Fred Brooks has blessed information hiding). Are there any well-known, published and/or outspoken critics of OO?

share|improve this question

closed as not constructive by gnat, Jalayn, Robert Harvey, MichaelT, Jim G. May 2 '13 at 20:24

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. If this question can be reworded to fit the rules in the help center, please edit the question.

It's "principles", not "principals". :-) –  CesarGon Mar 19 '12 at 14:24
@CesarGon - LOL yes, true, but they're also critics of those who espouse OO so I guess it could work either way... –  Xepoch Mar 19 '12 at 20:44
I wonder how it can be that all programmers on one hand admire OOP and dismiss it when say "composition over inheritance" on the other: valjok.blogspot.com/2013/01/… –  Val Jan 24 '13 at 19:12
"even Fred Brooks has blessed information hiding": In case you mean information hiding is something specific to OO design, it is not. –  Giorgio Apr 5 '13 at 1:06

3 Answers 3

I've seen many references to Why OO Sucks by Joe Armstrong. He makes some interesting points in this now-famous article, and believes that OO only became popular because it was believed to be easy to learn, was thought to make code reuse easier, received too much hype via the buzz word factory, and that it created a new software industry.

share|improve this answer
That article seems to be a giant pile of crap. "In an OOPL I have to choose some base object in which I will define the ubiquitous data structure, all other objects that want to use this data structure must inherit this object.". Really? I don't ever remember inheriting std::vector. In fact, many of his assertions are inherently subjective and he provides little reason for them. –  DeadMG Mar 19 '12 at 14:41
@CFL_Jeff Joe thinks that OOP says that the only way to reuse code is through inheritance, which is most definitely false. –  Michael K Mar 19 '12 at 15:07
@DeadMG: Joe is pretty clearly discussion "pure" OO languages like Smalltalk, which do enforce this restriction. It's quite true that std::vector doesn't (normally) inherit from anything else, but also true that std::vector isn't object oriented at all (in fact, Alexander Stepanov may not directly criticize OO, but makes very clear that he never uses OO-like things such as inheritance or virtual functions). –  Jerry Coffin Mar 19 '12 at 16:10
Interestingly, Joe Armstrong is one of the creators of Erlang, which is the mainstream (for a very loose definition of "mainstream" :-) ) language which actually most faithfully implements the definition of object-orientation. In fact, during his PhD thesis he worked with some of the pioneers of OO and came to realize that Erlang was an extremely object-oriented language, and he said in an interview that the above mentioned article is based on misinformation about what OO is and was only written to be provocative. –  Jörg W Mittag Mar 19 '12 at 16:52
Here's a more recent quote from Joe Armstrong about object-orientation: "Erlang might be the only object oriented language". –  Jörg W Mittag Mar 19 '12 at 16:53

There is a lot of criticism of OOP/OOD out there. Some of the relatively recent and well known criticisms are the ones by Joe Armstrong (creator of Erlang) and Rich Hickey (creator of Clojure).

In general, it seems there is little love for OOD/OOP among proponents of functional programming.

share|improve this answer
Which makes CLOS all the more interesting... –  Matthew Flynn Mar 19 '12 at 15:06
@MatthewFlynn Well, CLOS is an object-system inside a multi-paradigm language (although Common Lisp does allow you to write code in a mostly-functional style, there is nothing that requires you to). –  Vatine Mar 19 '12 at 15:48
This is quite interesting, considering that Erlang is probably one of the purest OO languages out there. Even Joe Armstrong himself says so: "Erlang might be the only object oriented language" –  Jörg W Mittag Mar 19 '12 at 16:55
"In general, it seems there is little love for OOD/OOP among proponents of functional programming.": The two approaches are specular in the way they organize data and operations: in OOP each type implements different operations whereas in FP each operation handles input data of different types. In OOP it is easier to add new types, in FP it is easier to add new operations. –  Giorgio May 2 '13 at 14:57

A good collection of arguments against OOP is available on the C2 wiki, where there's also a good collection of benefits of OOP.

Briefly, the benefits include:

  • localising the impact of any change;
  • provides a good model of the real world;
  • provides a good match to mental models;
  • makes it easy to do runtime configuration e.g. software product lines.

The arguments against include:

  • lack of consensus or rules on how to modularise OO code;
  • provides a poor model of the real world;
  • provides a poor match to mental models;
  • forces code to fit constrained taxonomies e.g. inheritance or polymorphism structures.

Notice that none of the points is uncontentious, and that some (including ones not mentioned in this summary) appear in both lists. There isn't a clear-cut answer to "object-oriented programming is [ba|goo]d", different people have different opinions of it in different contexts. I happen to think that the two articles linked here provide a good overview of both positions, with some valuable discussion on specific points available in both.

share|improve this answer
would you mind expanding a bit on what each of these resources have and why do you recommend these as answering the question asked? "Link-only answers" are not quite welcome at Stack Exchange –  gnat May 2 '13 at 16:41
@gnat sorry about that, I've improved the answer. –  user4051 May 2 '13 at 20:23
@GrahamLee If you are making a regular-expression joke, I think you mean "(ba|goo)d". Square brackets are for character classes; parenthesis for grouping. :-) –  GlenPeterson May 3 '13 at 2:58
@glenpeterson globbing. –  user4051 May 3 '13 at 5:52
@GrahamLee What kind of globbing? Unix-ish file globbing would be {ba,goo}d tomecat.com/jeffy/tttt/glob.html –  GlenPeterson May 5 '13 at 2:45

Not the answer you're looking for? Browse other questions tagged or ask your own question.