Remix.run Logo
ocrow 10 days ago

To unpack that a little, he looks to the writings of the early developers of object oriented programming and identifies the ways this assumption became established. People like Bjarne Stroustrup (developer of C++) took on and promulgated the view that the inheritance hierarchy of classes in an object oriented system can be or should be a literal instantiation of the types of objects from the domain model (e.g. different types of shapes in a drawing program).

This is a mistake is because it puts the broad-scale modularization boundaries of a system in the wrong places and makes the system brittle and inflexible. A better approach is one where large scale system boundaries fall along computational capability lines, as exemplified by modern Entity Component Systems. Class hierarchies that rigidly encode domain categorizations don't make for flexible systems.

Some of the earliest writers on object encapsulation, e.g. Tony Hoare, Doug Ross, understood this, but later language creators and promoters missed some of the subtleties of their writings and left us with a poor version of object-oriented programming as the accepted default.

igouy 6 days ago | parent | next [-]

> This is a mistake is because

https://news.ycombinator.com/item?id=44638183

mariodiana 6 days ago | parent | prev [-]

Is Objective-C discussed at all?

tmp10423288442 6 days ago | parent | next [-]

Only as a brief aside (don't have the timestamp right now) to talking about Smalltalk, which he mostly discusses to argue that Smalltalk was not different from C++ in seeking (most of the time) to model programs in terms of static hierarchies (according to the primary source documentation from the time of Smalltalk's design):

> And another thing is if you look at the other branch,

> the branch that I'm not really covering very much

> in this talk, because again,

> we don't program in small talk these days, right?

> The closest thing you would get

> is maybe something like Objective-C.

> If there's some people out there using Objective-C,

> you know, like Apple was using that for a little while,

> so Objective-C kind of came

> from a small talk background as well.

Objective-C is basically Smalltalk retrofitted onto C, even more than C++ was Simula retrofitted onto C (before C++ gained template metaprogramming and more modern paradigms), so it makes sense that Muratori doesn't go much into it, given that he doesn't discuss Smalltalk much.

Jtsummers 6 days ago | parent [-]

>> you know, like Apple was using that for a little while,

If we discount NeXT's time using it, Apple's only been using Objective-C for 28 years, just a little while. It also (barely) preceded C++.

6 days ago | parent | prev [-]
[deleted]