5 ms·
It's a shame that, in the minds of many, OOP has come to mean only: * chuck everything vaguely related in a class * share code by using inheritance IMHO, the
by ChrisSD 7y ago
It's a shame that, in the minds of many, OOP has come to mean only:
* chuck everything vaguely related in a class
* share code by using inheritance
IMHO, the way Java and C++ have been taught (in practice, if not by teachers) has done a disservice to OOP. So much so that many programmers now don't consider languages to be OOP unless they have the class keyword and inheritance.
- solipsism 7y agoIf you care about this, my advice is to not rail against words taking on new meanings. That's how language works, and it's a losing battle to fight against it. Just take what you believe is the better definition of OOP and rebrand it.
- AlchemistCamp 7y ago> That's how language works, and it's a losing battle to fight against it. The very name of this site is a powerful argument to the contrary. Slashdotters initially dissed it, saying the word "hacker" (as in coder or builder as opposed to criminal) should be retired. Now the older sense of the word is widespread enough that people halfway around the world are aware of hackers in the sense that PG named this forum. Indie Hackers is only further cementing the reversal of the trend that once appeared inevitable.
- js8 7y agoBernie Sanders calling himself "socialist" (although he could also use social democrat) is a very similar example.
- solipsism 7y agoHackers don't have the need to convince anyone else of what the word hacker means. It is of no consequence what "regular people" think we mean when we say hacker. We have our forums and our and we all know what it means. But if we were in a situation where it mattered what other people I thought the word meant, then we would be fucked. And that is evident by just talking with regular folk and asking them what they think about hackers. The situation with OOP is different. It is our community itself that uses the word incorrectly (according to some people, including the original commenter).
- monocasa 7y agoI've got a linguistics minor. The concept here is prescriptivism versus descriptivism. The linguistics community overall has a huge emphasis on descriptivism. Trying to enforce consistency of language is a Sisyphean task, and in a lot of ways is an element of imperialism. Words change, grow, gain and lose definitions and shades over time. Document the new uses, and let people live their lives.
- ChrisSD 7y agoI don't see things in such absolutist terms as that. For everyday language, sure, I'm more than happy to go with the flow. For technical language we need a relatively stable, agreed upon terminology. Terms that flow and change too freely makes communication very difficult and often leads to people having pointless arguments due to fundamentally misunderstanding what each person is saying. And I do disagree that it's Sisyphean. Raising awareness can and does influence how words are used (especially within a group).
- anoncake 7y agoThe meaning of a term depends on its usage. That is not a matter of opinion, it's how language, including technical language, works. Currently "OOP" roughly means [Alan Kay's vision] or [Java-like]. That is an imprecise and mostly useless definition but it's the one it has, whether we like it or not. A stable terminology is desirable and that's why we shouldn't redefine "OOP". Think of it like an API. What's more backwards-compatible: changing the behavior of oop() or deprecating it in favor of javaLikeProgramming() and kayProgramming() ?
- hombre_fatal 7y agofwiw, a minor (so, ~4 uni classes) is not what I would flex as credentialization in a subject. Especially when you go on to bring up such an elementary part of linguistics. It's kind of like introducing yourself as a compsci minor and then explaining OOP vs FP. I'd just leave off the creds, there's no need.
- monocasa 7y ago
- goto11 7y agoIt is futile to rail against other people using words "wrong". But that doesn't mean you can't use words in the "correct way" yourself. If you are influential enough it may even have an effect. In the case of "hacker" it has a different meaning in the media and the general population, but this is not a problem because the audience of HN understands the intended meaning.
- mwcampbell 7y ago> The very name of this site is a powerful argument to the contrary. In our little bubble, perhaps. But I'm pretty sure that to my family and non-techie friends, "hacker" has only the negative meaning. That's why, when I tell them in general terms about what I'm doing during a hackathon at work, I don't use that word.
- MaxBarraclough 7y ago> many programmers now don't consider languages to be OOP unless they have the class keyword and inheritance. If a language doesn't support inheritance, in what sense is it an object-oriented programming language? It's true that you can use OOP principles in languages that don't have language-level support for OOP. The canonical example of this is the GObject library for C. That doesn't tell us how we should use the term object-oriented programming language though. I don't see why we'd use a more expansive definition.
- magicalhippo 7y agoThinking off the top of my head, how about a language that only had interfaces (ala COM)? Implemented by non-inheritable objects, using delegation instead of inheritance to share code. I imagine some syntax sugar to help with the delegation to make it less cumbersome.
- hhas01 7y agoSelf doesn’t have classes or inheritance, and it’s as [single-dispatch] OO as they come. (Certainly moreso than something like C++, which wouldn’t look out of place on a Melanesian island. Never could figure why C++ and all its typed kin would choose to dispatch [dynamically] on only one argument instead of on all. Playing to their weaknesses, no?)
- MaxBarraclough 7y agoMy guess is that by going with single dispatch, you get clear 'ownership' in terms of methods^H^H^H^H^H^H^H member-functions belonging to classes. Can't say I know a lot about multiple-dispatch though.
- int_19h 7y agoIn every sense. Prototype-based OO has been a thing for a long time now. If you look at the entire breadth of OO languages and see what they have in common, there's really only two things that are truly common: object identity, and some form of dynamic dispatch based on that. Everything else - inheritance, encapsulation etc - is optional.