# wo84LFzx5nI transcript
# Source: https://www.youtube.com/watch?v=wo84LFzx5nI
# Title: The Big OOPs: Anatomy of a Thirty-Five-Year Mistake
# Speaker: Casey Muratori
# Conference: BSC 2025 (Better Software Conference)
# Fetched: 2026-06-08
# Segments: 4310

---

[00:00] Please join me in welcoming the one, the
[00:02] only, the irreplaceable Casey Muradori.
[00:19] Okay. Okay. Way too big. Sam Sam made it
[00:22] way too big. I feel like before we
[00:25] start, we should also thank Sam for
[00:26] putting this together.
[00:33] Uh it's been a very long time since I've
[00:34] been really excited to give a talk and
[00:36] uh a lot of that is because the the the
[00:39] speaker list of this talk is is of this
[00:41] conference is absolutely amazing and I
[00:43] just I don't know I'm I'm really excited
[00:45] to be here and I'm excited to give this
[00:46] talk. So I'm just going to jump right
[00:47] into it. So, I would like to talk about
[00:50] something that happened in 1998 at a
[00:52] company called Looking Glass, which
[00:53] normally like back in the day,
[00:55] contemporaneous with this, if I had said
[00:57] Looking Glass, everyone would know who
[00:58] they were because they were incredibly
[01:00] influential game company that did a lot
[01:02] of uh firsts in gaming. Uh, one of their
[01:05] games, Ultimate Underworld, started kind
[01:07] of the 3D revolution in, you know, PC
[01:09] gaming. And they they were incredibly
[01:11] like innovative company at the time. And
[01:13] a lot of people today, I mean, there's
[01:15] people in the audience here who weren't
[01:16] even born then, right? So, a lot of
[01:18] people they might not know who they
[01:19] were, but they were incredibly
[01:20] important. And one of their games uh was
[01:22] called Thief: The Dark Project. And it's
[01:24] a franchise that lived on. It was one of
[01:26] the first sort of stealth action games.
[01:29] And it looks pretty primitive by today's
[01:31] standards, obviously, but this was a
[01:33] engine contemporaneous with things like
[01:35] Quake, for example. So, this was sort of
[01:37] state-of-the-art at the time. Now, I'm
[01:40] not going to talk about graphics because
[01:41] I'm not qualified to talk about graphics
[01:43] anyway. I'm not a graphics guy. What I
[01:45] want to talk about instead is how they
[01:46] modeled entities. And normally the way
[01:50] you would do things in games at this
[01:51] time and in fact the way that Ultimate
[01:53] Underworld 1 and two and then later
[01:54] System Shock was another one of their
[01:56] games. The way that they did things was
[01:57] actually the way that like uh me and for
[02:00] example Ryan Flurry who's going to be
[02:01] interviewing you after we would say that
[02:02] this is a good way to do things even
[02:04] today. They were sort of fatrus if you
[02:06] will. They just put everything in one
[02:08] structure and when you were going to do
[02:10] things like have different types of
[02:11] entities really all you had was some
[02:13] kind of a type field in there or flags
[02:15] or things like that that would let you
[02:16] know what you were supposed to do with
[02:17] it. But you know these were very very
[02:20] limited resource times. I think the
[02:21] systems uh you know you would expect to
[02:23] have something like 2 megabytes of
[02:25] memory or something total to run in. So
[02:27] you're talking about fixed blocks of
[02:28] small size and everything has to work in
[02:29] that. So that's just what you did
[02:31] because that's what worked. And in this
[02:34] time frame, right? You know, during the
[02:36] 80s and then later 90s when this game
[02:38] was made, this is the sort of thing that
[02:39] was in vogue in like the architecture
[02:41] world. This is nothing to do with how
[02:43] they were doing things at looking glass.
[02:44] This is what we would kind of think of
[02:47] as a normal like oop programming model
[02:48] now where you have a hierarchy of things
[02:50] like there's an entity class and then
[02:52] you have an NPC and item subclass
[02:54] derived from it and then things below
[02:56] that and so on. And that was not
[02:58] something that Looking Glass had ever
[03:00] really used in that lineage of games in
[03:02] their RPGs. And they decided not to go
[03:05] that route even though that was sort of
[03:07] what was in vogue at the time. That was
[03:09] what was uh you would have seen pushed
[03:10] if you were reading like architecture
[03:12] things in oops law or you know the kinds
[03:14] of papers that would have been published
[03:15] on software architecture. So they did
[03:18] something very different. What they did
[03:20] is said look we want all of our systems
[03:23] to be the primary thing that we're going
[03:25] to think about. We want to think about
[03:26] physics and combat and those sorts of
[03:28] things. The same things that were in our
[03:30] fatty strus when we do a more serious
[03:33] architecture here doing more
[03:34] architectural work. We want to put
[03:36] things in terms of their system not in
[03:39] terms of the entity. And so what they
[03:41] did is they came up with a system where
[03:43] they would use an ID. Like if I have a
[03:45] particular object that I'm trying to
[03:47] model in the world, one of these
[03:48] entities, I just have an ID for it and
[03:50] it doesn't really have any data
[03:52] associated with it at all. It's kind of
[03:53] the polar opposite of a fat strct. So
[03:56] they would just say we're going to use
[03:57] the ids to represent things and then the
[03:59] way that we form the entity's data is we
[04:02] just use that ID to look up into a
[04:05] system and say what's the physics like
[04:07] for this thing? What's the combat like
[04:08] for this thing? This fuel system I have
[04:10] or I'm just imagining systems you might
[04:11] have in a game. And in so doing, in 1998
[04:16] when they shipped Thief the dark
[04:17] project, they shipped to the best of my
[04:19] knowledge the first instance of an
[04:21] actually commercially released entity
[04:23] component system. That's what we call it
[04:25] today, right? People call it this. Uh
[04:27] this is now in an invogue architecture
[04:29] in much the way that those hierarchy
[04:31] kinds of architectures were in vogue at
[04:32] the time and still to some extent are in
[04:34] today, but not necessarily in the game
[04:35] industry. So, this is the first time I'm
[04:38] ever aware of anyone shipping this kind
[04:40] of model. And in fact, it's the first
[04:41] time I'm aware of anyone even talking
[04:42] about this kind of model. I'd never
[04:44] heard of it before. This was the first
[04:45] time. And there's a a pretty interesting
[04:48] thing that you have to understand about
[04:50] this. And I know this may seem like
[04:51] beating a bit of a dead horse here, but
[04:54] those red lines that I've drawn there
[04:56] are basically encapsulation boundaries.
[04:57] And this is a very important theme
[04:58] throughout this talk. I just want to
[05:00] really make sure I hammer it home.
[05:02] Encapsulation boundaries are really what
[05:03] we care about when we're doing
[05:04] architecture. What we care about is
[05:06] where we make it difficult to access
[05:08] things and where we make it easy, right?
[05:11] And so what they chose to do that was
[05:13] very different than that sort of
[05:15] inheritance hierarchy model is they
[05:16] chose to draw the encapsulation
[05:18] boundaries around the systems. Now this
[05:21] is very different because the
[05:22] traditional oop model, right, is you
[05:24] draw the encapsulation boundaries around
[05:26] the objects. So the encapsulation
[05:29] boundary in a normal oop like hierarchy
[05:31] is I have whatever the object is like a
[05:33] mech and the encapsulation boundary is
[05:35] around all of the things that the mech
[05:37] knows about. But that's very different
[05:39] than this. This is about all of the
[05:41] things that are related to a system not
[05:43] all the things that are related to a
[05:45] mech. Now it's important to remember
[05:47] this is not like not oop you could
[05:50] easily call this object-oriented
[05:51] programming. It still obeys a lot of the
[05:53] principles you might recognize from
[05:54] object. It's not like they were saying
[05:56] we're getting rid of object-oriented
[05:57] programming. They were saying something
[05:59] very different. And they were saying
[06:00] effectively what Mark Blank said, he's
[06:03] the person who actually uh implemented a
[06:06] lot of the system. And what he said was
[06:08] for some reason oop has gotten into this
[06:10] mindset of compile time hierarchies that
[06:13] match the domain model. Meaning, if you
[06:15] think about what you're trying to model
[06:16] in the real world, like entities and
[06:18] guards and things like this, or even if
[06:20] you're just thinking like the natural
[06:21] world, we're going to think about, you
[06:23] know, birds and are they, you know, is
[06:25] it a mammal or is it an aven thing,
[06:27] right? You're thinking about this domain
[06:29] model that you're trying to model in the
[06:30] real world and you're bringing it into
[06:31] the software world. And what he was
[06:34] saying is like why are we pushing this?
[06:36] Why is that the idea, right? And he says
[06:39] we can still do oop style stuff and we
[06:41] can just do it by changing our paradigm
[06:43] of what we're thinking about in terms of
[06:45] our domain model, right? Don't don't
[06:47] make the domain model be in the code.
[06:49] Make that be something the user
[06:50] experiences, but the code is done in a
[06:52] way that makes sense for the code. So
[06:55] this is really brilliant and it's a
[06:56] great way to summarize it. It's one of
[06:57] my favorite crystallizations of that
[07:00] concept. So I would only add one thing
[07:03] to it and that's that word encapsulation
[07:05] because I think sometimes people think
[07:06] hierarchy they just think the
[07:07] relationships but it's the encapsulation
[07:09] that's really important because that's
[07:11] what really determines whether or not
[07:12] the code is easy to write or hard to
[07:13] write. It's are those boundaries in the
[07:15] right place. So this is crucial and this
[07:21] talk is kind of about mistakes as you'll
[07:23] see and I made a mistake one time. I
[07:26] went on this thing uh you may have seen
[07:28] it. It's called the internet. It's like
[07:30] this series of tubes that connects
[07:31] people around the world. And it's it's
[07:33] kind of complicated. I'm not 100% sure
[07:35] how it works, but they have a thing on
[07:36] it called social media where what you
[07:38] can do is there's like a box and you can
[07:40] type anything you want into the box. It
[07:41] doesn't have to be correct. It could be
[07:43] it doesn't have to be coherent. It
[07:44] certainly doesn't have to be polite. And
[07:46] then you have to push this button.
[07:47] There's usually a button next to it, but
[07:48] the button says different things
[07:49] sometimes. You push the button and
[07:51] everyone in the world has to read it.
[07:52] Like everybody.
[07:54] And that's an amazing invention. And I
[07:55] was probably doing something like that
[07:57] at the time when I saw uh some people
[08:00] talking you having a discussion about
[08:01] this sort of thing discussion in quotes
[08:03] let's say
[08:04] and they were thinking about this they
[08:06] were thinking about you know we you know
[08:08] we have old old things that were like
[08:09] maybe not quite architecture like those
[08:11] fatty strus things and at some point
[08:13] people started saying you know there's
[08:14] this other architecture we could do
[08:16] which is this hierarchy thing and that's
[08:17] like much you know cleaner it's much
[08:19] better organized it's better
[08:20] architecture and they started to push
[08:22] this right and it definitely got adopted
[08:24] got adopted everywhere and it's a very
[08:27] standard paradigm even to this day and
[08:29] they were they were sort of responding
[08:30] to people who are saying this is bad
[08:32] that this hierarchical thing is not a
[08:34] good idea the capsulation boundaries are
[08:35] in the wrong place as I would say and
[08:38] they're saying okay there's no way that
[08:41] all of these smart people who pushed
[08:43] this stuff and who created this there's
[08:44] no way they could possibly be wrong
[08:46] about it right like surely this comes
[08:48] from all kinds of like academic studies
[08:50] and ways of looking at things and we've
[08:52] we definitely have great examples of
[08:54] this working perfectly, I'm sure, and it
[08:56] all got translated to us and you guys
[08:58] just don't understand. And you know, we
[09:00] don't understand either because we're
[09:00] not really sure what we're saying, but
[09:02] we're basically saying that someone must
[09:03] have known and those people were smart.
[09:05] So there you go. Right? So could you
[09:08] really be saying all you naysayers that
[09:12] it it it doesn't make sense. It didn't
[09:13] come from a logical place. And so the
[09:16] short answer to that is absolutely
[09:18] that's what we're saying. That's 100%
[09:20] what we're saying. And the long answer
[09:22] to this is the rest of this talk.
[09:25] Welcome to the Better Software
[09:26] Conference, the inaugural Better
[09:28] Software Conference. This is the big
[09:30] oops, which is my sort of attempt to go
[09:32] back over 35 years of history
[09:36] to figure out where we went wrong like
[09:39] how did this happen? Okay, now just get
[09:43] some things out of the way first. And
[09:44] this is mostly for the people I don't
[09:46] know where I'm looking. Is there a
[09:47] camera out there? That this is mostly
[09:49] for the people. The people in this room
[09:50] are probably already bought in, right?
[09:52] Low-level programming, that sort of
[09:54] thing. You're probably like, "Okay, I
[09:55] like where this is going." People on the
[09:57] internet, as I said before, you know,
[09:59] maybe that was a mistake, but they're
[10:00] going to have some some uh some issues
[10:02] with some bones to pick. So, I just want
[10:04] to say first, when I say the big oops
[10:07] anatomy of a 35-y year mistake, I'm not
[10:10] talking about uh OOP as a whole. I'm
[10:12] talking about looking for very specific
[10:14] things in it. Okay? And because whenever
[10:17] you talk about oop, it's always this
[10:18] thing where people feel like, well,
[10:19] whatever you're talking about, like
[10:20] that's not really OOP. Like you're
[10:22] you're talking about the things you're
[10:23] using the terminology wrong or that's
[10:24] not how I write code. It's like oop is
[10:25] just a thing where it's like it's how I
[10:27] like to write code and whatever they're
[10:29] thinking at the time, that's what OP is
[10:31] or something. And and I don't
[10:32] necessarily blame them because it's a
[10:33] nebulous term and they have their own
[10:34] definition for I mean I probably have my
[10:35] own definition for that's totally fair,
[10:37] right? But I just want to say we're not
[10:39] going to be dealing with any of that
[10:40] here. So, I don't want to hear the the
[10:42] whole like, you know, I don't know. It's
[10:44] sort of like like wine, which I got the
[10:45] slide up in here. It's like you if you
[10:46] have like a designated origin, you
[10:48] you're not allowed to call it certain
[10:49] things. And it's like it's that kind of
[10:50] feel, right? It's not like it's like
[10:52] it's not actually oop, it's sparkling
[10:53] code or something like this. You have to
[10:55] use the right term for it. So, I just
[10:57] want to be clear. I'm talking about
[10:58] something very specific. And it's the
[10:59] thing that I just said, very, very
[11:01] specific. And I'm not saying it was a
[11:02] mistake. I'm saying this was a mistake.
[11:05] the idea that you're going to draw
[11:06] encapsulation boundaries around these
[11:08] compile time hierarchies that are based
[11:10] off of whatever you're trying to write.
[11:12] Now, second thing we want to get clear
[11:15] is I don't want to hear any complaints
[11:18] that no one ever pushed this model
[11:20] because I know that's going to happen.
[11:22] I'm looking at UI Combinator. I know
[11:24] that this is going to be a threat. So,
[11:27] anticipating that, let's just say we
[11:30] have a lot of historical evidence. When
[11:31] I was doing the research for this talk,
[11:33] I read so many things from the
[11:35] historical record. It is so obvious that
[11:38] everyone actually 100% meant you should
[11:41] look at the domain model and you should
[11:42] code that directly into compile
[11:44] hierarchy. For example, here is
[11:47] literally Bjarn Strus's paper. What is
[11:50] object-oriented programming to tell you
[11:52] what it is?
[11:54] And he starts off with a shape example
[11:56] that I've used before that everyone
[11:58] said, well, that's totally ridiculous.
[11:59] you're just cherry-picking out of an
[12:00] introductory book. It's like this is
[12:02] where he was trying to explain this and
[12:04] sell this to people in his industry who
[12:06] were experts.
[12:08] And he says, look, if we're going to
[12:09] write something like this that has, you
[12:11] know, kind k is an enumerate there of
[12:12] like what the kinds of shapes are,
[12:14] right? If we're going to write something
[12:16] like this, we end up with code that has
[12:17] a switch statement in it. So we want to
[12:19] draw something, we have to say, oh, what
[12:20] what is this? And I have to say, okay,
[12:22] case circle, case triangle, and have the
[12:23] different drawings for that. And he's
[12:25] like, this is a mess. You you can never
[12:27] do something like that. Instead, what
[12:29] you want to do is make a hierarchy where
[12:31] it matches the domain model. I've got a
[12:33] shape class and then he deres from it
[12:34] the triangle class and has a virtual
[12:36] function and all those sorts of things.
[12:37] This is right in the first papers where
[12:40] people are selling this concept in
[12:42] certain programming languages, right?
[12:44] And I guess I should also point out that
[12:47] he says things like when we're talking
[12:49] about objective programming, literally
[12:50] what we're talking about is inheritance
[12:52] hierarchies with virtual function calls.
[12:54] like he says that and he says object
[12:57] programming is programming using
[12:58] inheritance so hammering home that this
[13:01] is literally what we are talking about
[13:02] there's so much evidence and I'm just
[13:04] picking one paper now a lot of people
[13:06] will talk about say Alan K because he
[13:09] was a big father of a compar he's the
[13:11] one who coined the term as far as anyone
[13:12] knows
[13:14] uh and he talks about you know uh this
[13:17] this sort of idea that oop only means
[13:19] like messaging and a few other things
[13:21] right he's said this and so some people
[13:23] might be like well That's what object
[13:24] programming was really about. No one was
[13:26] ever pushing it. And and you know,
[13:27] Jerus, okay, whatever. C++ is terrible.
[13:29] Like he that don't listen to that guy,
[13:31] right? Despite the fact that he made the
[13:32] language that's like one of the most
[13:33] prevalent, it's the one that we all use
[13:35] mostly or at least have for the past 20
[13:37] years. And so this this is the truth.
[13:40] This is the actual truth here. It's
[13:41] like, yeah, he said that in 2003, right?
[13:44] He said that after a very long time. So
[13:47] why did he say it? It's because 10 years
[13:49] earlier, he was already saying he kind
[13:51] of soured on it. He's like, "Inheritance
[13:52] was like really powerful, but people
[13:54] just didn't know how to use it. Novices
[13:56] and experts apparently both couldn't use
[13:58] it, right? It was just uh you know, it's
[14:00] really good, but no one can figure out
[14:02] how to use it, I guess. Uh so that's a
[14:04] little bit weird. I don't know. Maybe
[14:05] Alan K, he still comments on stuff.
[14:07] Maybe he'll come to tell us what he
[14:08] actually was trying to say there
[14:10] exactly. But if you go back earlier,
[14:12] because small talk is a lot earlier that
[14:13] if you go back look at what they were
[14:14] actually talking about when they were
[14:15] talking about small talk in the times
[14:17] before they had chance to reflect and
[14:19] say that it didn't work." Well, here's
[14:21] what they were saying. Inheritance
[14:22] programming shows the power of
[14:24] differential description, right? They're
[14:25] like, you can take an object and I can
[14:27] say like, I'm going to start with
[14:28] completely undifferiated object and then
[14:30] I'm going to derive a rectangle. I'm
[14:31] going to drive drive drive. And in fact,
[14:32] here is a diagram from one of his
[14:34] articles talking about like cool things,
[14:36] computer architecture. He's like, we can
[14:38] have a generic object and then we can
[14:40] drive from that a rectangle and we'll
[14:41] drive a window and a painted window and
[14:43] a browser. Look, everyone is talking
[14:46] about literally representing in the
[14:49] hierarchy what your domain model is.
[14:51] That's what they're talking about. And
[14:53] if you need further proof, look at
[14:54] what's actually in small talk. We have
[14:56] all the data like for this all of the
[14:58] papers exist. Here is an example from
[15:01] the art and science of small talk where
[15:02] they're talking about some stuff that's
[15:04] needed to adapt values like I want to
[15:06] convert values between things and you
[15:08] know actually exchange values between
[15:09] objects and stuff like this. And here's
[15:11] just a hierarchy that they drew of stuff
[15:13] that they were using for implementation.
[15:15] That's the hierarchy, right? And if you
[15:17] look, it actually says, well, it's only
[15:20] part of the hierarchy for this thing
[15:21] cuz, you know, like we couldn't fit it
[15:22] on the diagram we had so many classes we
[15:25] were inheriting here, right? And guess
[15:27] what? If you liked the shape example
[15:29] that keeps coming up that everyone says,
[15:31] well, no one would ever actually suggest
[15:33] that you use this sort of ridiculous
[15:35] shape example. You know, you're just
[15:36] cherry-picking. Except it exists
[15:38] absolutely everywhere. It's in small
[15:40] talk. There it is. They have a path
[15:42] class and from that path class they have
[15:44] different shapes derived from it. That's
[15:46] what this the path looks like. That's in
[15:48] the base language of small talk that
[15:51] Allen K and uh Robson shipped and Adele
[15:53] Goldberg was the person who documented
[15:54] it. These are the original authors of
[15:57] small talk. Right? And if you don't want
[15:59] to take my word for all of that, you can
[16:01] take Bjarn's word for it. He criticizes
[16:05] small talk for being all about
[16:06] inheritance. that that's all it was and
[16:09] you had to actually use it to get
[16:10] anything done in that language, right?
[16:12] And he's actually saying C++ at least
[16:14] doesn't make you do it that way. You
[16:16] only have to do it that way when you
[16:17] think it's a good idea, right? Which by
[16:19] the way, I agree with him on that.
[16:20] That's why we were able that's why I'm
[16:22] still able to use C++ to this day is
[16:23] because Bjan Stra was actually really
[16:25] smart about a lot of things and he
[16:27] didn't try to force you to do things
[16:28] only his way where Small Thought kind of
[16:30] did.
[16:32] All right. So, now that we've got that
[16:34] out of the the way, let's talk about the
[16:36] origin story for this guy right here who
[16:38] has caused me so much pain. And you
[16:41] know, I won't go into it. Anyway, let's
[16:43] talk about the origin story. So we'll
[16:45] start uh with C++ because obviously
[16:48] that's the most impactful language that
[16:50] really promulgated this inheritance
[16:52] hierarchy concept out to the world in a
[16:54] way that we all kind of experienced not
[16:57] only in programming C++ but obviously
[16:59] languages like Java which are incredibly
[17:01] prevalent in not exactly our circles
[17:03] maybe but obviously in business world
[17:05] and that sort of thing. So it's it's not
[17:07] even just C++ it's like the knock-on
[17:09] effects of C++ also. So this is really
[17:11] really important uh as an entry into
[17:13] where this came from. Let's start in
[17:15] 1978 and looking at that and uh Bjnusup
[17:18] is actually in the uh he's in university
[17:21] at this point. He he hasn't actually
[17:22] gotten to Bell Laboratories where he
[17:24] would do uh the later work on C++.
[17:26] So he is working on his PhD thesis. And
[17:29] again as I'm going through the
[17:31] historical record here I really want to
[17:32] try and give you a mindset of what the
[17:36] people were thinking as far as I could
[17:37] get it from their writings. Right? I
[17:39] went only through primary sources for
[17:41] this and I tried to figure out what were
[17:43] these people feeling like what were they
[17:44] doing when they were coding and so he is
[17:47] actually working on distributed systems
[17:49] he's not a languages guy he's not there
[17:51] like researching languages or anything
[17:53] like that he's working on distributed
[17:54] systems and what he wants to know is
[17:57] look we've got some stuff where we want
[18:00] to know about hardware protection like
[18:02] you know if you kind of think of virtual
[18:03] memory or things like that where you
[18:04] have hardware features uh that are
[18:06] designed to protect different parts of
[18:08] your program from other different parts
[18:10] of your program or different processes
[18:11] from each other or different nodes in a
[18:13] system all those sorts of things. So
[18:14] he's doing distributed architecture work
[18:16] and what he wants to do is run
[18:18] simulations because at the time again
[18:20] putting you in the mindset of where we
[18:21] are in computer history you don't just
[18:23] have computers lying around like we do
[18:25] today right it's not like oh I can just
[18:26] buy a bunch of computers and set up a
[18:28] network and do testing on it's like no
[18:30] there's no way he was going to get
[18:31] things like a distributed multiprocessor
[18:33] system to just play around on in 1978
[18:35] unless he was extremely important in
[18:37] working for the military or something
[18:38] like that right
[18:40] so what he had to do was write a
[18:41] simulator and what he decided to to to
[18:44] write the simulator because earlier in
[18:46] his career he had well he'd been in
[18:48] university I guess early his education I
[18:49] should say he had been at university and
[18:51] he learned uh from a person named
[18:53] Kristen Nygard who was actually one of
[18:54] the creators of simula he learned the
[18:56] language simula directly from one of its
[18:59] authors basically like he he was
[19:00] actually there at the time uh when the
[19:03] author was also there and this this was
[19:05] how he knew what simula was and how to
[19:06] use it and so what he did was he wrote a
[19:09] simulator for distributed systems in
[19:11] simula which is kind of exactly what
[19:13] it's designed for, right? It's a
[19:14] simulation language. And he had a great
[19:17] time doing it. He was like, "This was so
[19:19] much better than what I'm used to. I
[19:21] really liked the experience of writing
[19:23] that." So, he ended up with this thing
[19:25] where he had like little programs that
[19:26] were simulating what was happening in a
[19:28] distributed network uh or distributed
[19:30] system, I should say, not necessarily on
[19:31] a network. And he found that it was
[19:33] really easy to debug the little programs
[19:34] by themselves. And the language made it
[19:36] really easy to do that. Now, again, it's
[19:38] important to remember keeping all this
[19:39] in your head if you can. I know it's a
[19:41] lot. Uh it was it was a lot of reading,
[19:42] right? So I'm trying to convey it to you
[19:44] in in case possible just pointing out
[19:46] it's important to remember that that's
[19:48] the domain model he was working with is
[19:50] lots of little programs that were
[19:51] talking to each other right
[19:53] so anyway he says that the class concept
[19:55] the simula had because it had the same
[19:57] sort of idea of a class as C++ would
[19:59] later have he said that that class
[20:02] concept that simula had was really good
[20:06] for direct mapping right remember I said
[20:09] compile time hierarchy that exactly
[20:11] models the the domain right? He said
[20:13] that was working really well when he was
[20:15] implementing. He was just saying, "Oh,
[20:17] this is the thing I'm trying to simulate
[20:18] and so I'm literally going to create
[20:20] classes in Simula that model that
[20:22] directly." And that was working really
[20:23] well for him in Simula. And you know, we
[20:25] can kind of start to see how this is
[20:27] breaking down. He happens to be working
[20:29] on something that is literally a domain
[20:32] model of things that are encapsulated.
[20:34] The computers can't talk to each other.
[20:36] The different processes in the computer
[20:38] can't talk to each other. It's an exact
[20:40] fit for what a class actually does. This
[20:44] is important to remember. Okay, so we
[20:47] used hierarchies for this, right? They
[20:49] weren't necessarily particularly deep,
[20:50] but they were the kind of thing where
[20:51] it's like, I have a computer. I derive
[20:52] different things from the computer, and
[20:54] those things are just kind of
[20:55] self-contained. And he had a really
[20:56] great time doing this. Again, he said
[20:58] very positive things about it. And one
[21:00] of the things that he really liked was
[21:02] the fact that the type system, when you
[21:04] had these hierarchies, that type system
[21:06] would catch errors for you. Exactly the
[21:07] kind of thing that we maybe take for
[21:09] granted today because most languages
[21:11] even JavaScript now has like TypeScript,
[21:13] right? Most things that we work with
[21:14] today have the ability for you to do
[21:16] this kind of type checking that catches
[21:17] a lot of errors at compile time. That
[21:19] was relatively new at the time. And I
[21:21] don't mean new in the terms of like no
[21:23] one had ever thought about it before,
[21:24] but I just mean a lot of languages you
[21:26] might be using at this time still had
[21:27] very weak type systems. And in fact,
[21:30] Struestrip complains directly when he's
[21:32] talking about this that using Pascal
[21:34] kind of sucked and he didn't really like
[21:36] it because the type system didn't work
[21:38] very well for expressing things and for
[21:40] catching errors. He felt it was kind of
[21:42] more trouble than it was worth. So that
[21:45] forms his basis for this idea that
[21:48] classes are really good and typeecking
[21:50] on classes is really good, right? And
[21:53] you know just to split those down the
[21:54] middle, I do think the type-checking
[21:56] part is pretty good. maybe the class
[21:57] part or rather the hierarchy part that
[21:59] I'm like a little bit suspicious of,
[22:00] right? But at least half of it I'm with
[22:02] him on already even. Okay, so that's
[22:06] sort of what you will see if you read
[22:09] the Wikipedia or something, right?
[22:10] That's the simple part and they often
[22:12] leave a lot of stuff out. So I thought
[22:14] because this is the better software
[22:16] conference I would include a much more
[22:18] interesting aspect of this story because
[22:20] you would think if you saw a thing
[22:21] that's like hey uh what happened was
[22:24] Bjnestrip was doing stuff with
[22:26] distributed systems and he wrote this
[22:27] thing in simula and it was a great time
[22:29] and so he decided to do when he got to
[22:31] Bell Labs was make C++ and it it would
[22:34] just have you know the classes in it
[22:35] from Simula. It was great. No. So what
[22:38] actually happened was
[22:41] the entire thing completely rolled over
[22:43] and died. He tried to run the simul
[22:46] program and he had all sorts of problems
[22:49] with it and it started even before he
[22:51] tried to run the simulate programs that
[22:53] he was writing. What actually happened
[22:55] is first he hit the same things we hit
[22:57] with C++ today. Build times were through
[23:00] the roof and it was almost impossible to
[23:03] make changes to the program. So much so,
[23:06] and I'm going to let this sink in for a
[23:07] second because it's really awesome. So
[23:09] much so
[23:12] I I mean, I almost want you to read it.
[23:17] If you compiled 130th of the program and
[23:19] tried to link it, it was slower than
[23:21] just recompiling the entire thing. Okay,
[23:25] let that sink in because it means that
[23:27] that Bja was talking about Unity builds
[23:32] in 1994. He was like, "We can speed this
[23:35] up by not doing incremental."
[23:37] Incremental builds sucked that long ago.
[23:41] Anyway,
[23:43] but I digress.
[23:45] Anyway, the runtime also was lousy. He
[23:48] couldn't get the thing to run fast
[23:49] enough because Simulo was extremely
[23:51] slow. Anyone want to guess why it's
[23:53] slow? It's a rhetorical question. I'm
[23:54] going to tell you why it's slow. It was
[23:55] so because the garbage collector, same
[23:57] reason things are slow today half the
[23:59] time. The garbage collector was taking
[24:01] any 80% of the runtime apparently even
[24:03] though there was no actual garbage that
[24:04] needed to be collected because you know
[24:06] I guess at that time garbage collection
[24:07] was even you know very very primitive
[24:09] obviously so it's probably running all
[24:10] the time just to see if there was any
[24:12] garbage and it was like
[24:15] yeah nope no garbage and that was
[24:16] happening a lot so 80% of the time so he
[24:18] had he had the experience with simula
[24:20] that we have with C++ like it is the
[24:22] chain continues right uh the garbage
[24:25] collection obviously not so much so
[24:27] that's what happened he had to rewrite
[24:28] the whole thing from scratch in a
[24:30] different language called BCPL which has
[24:32] no type checking whatsoever.
[24:35] I mean that's not entirely true. It has
[24:36] very very minimal but none of those
[24:38] class things and that sort of thing. So
[24:40] that's the actual story of what
[24:41] happened. So it's kind of interesting.
[24:43] It precages everything, right? It kind
[24:44] of the whole thing is almost like a
[24:45] microcosm. So if we reflect on this for
[24:48] a second again I think I've tried to
[24:49] highlight the important points there but
[24:51] the other thing to remember is a lot of
[24:52] people talk about these things. They
[24:54] talk about those compile time
[24:55] hierarchies and all that sort of stuff
[24:56] and they say like, you know,
[24:59] here's the thing that you just don't
[25:01] understand. It's all about large teams.
[25:04] You know, it's all about these large
[25:05] teams. It's just that you got to have
[25:07] large teams. And if you had large teams,
[25:09] then you would understand the magic of
[25:12] the compile time hierarchy stuff and the
[25:14] encapsulation. It's amazing, right?
[25:17] How big was the team that Bjestro was
[25:19] working with when he figured this stuff
[25:20] out and thought it was good? one, he's
[25:23] doing the same thing we're doing. So
[25:25] these ideas don't come from some kind of
[25:28] a like analysis of what we're going to
[25:31] do with lots of people. So you could
[25:33] argue maybe they turn out to be good for
[25:35] that. But you certainly can't argue they
[25:36] was designing it for that because they
[25:38] weren't. They were doing it for
[25:40] themselves. Strus was doing it for the
[25:42] the protection, the type protection, the
[25:43] error checking, that sort of thing. He
[25:45] wasn't doing it to and also like the
[25:48] virtual function kind of stuff. He
[25:49] wasn't doing it uh for large teams
[25:51] because everyone at Cambridge University
[25:52] was helping out in the product. No, he
[25:53] he was a lone wolf coder. He really was.
[25:56] So anyway, goes to Bell Labs. He makes C
[25:59] uh with classes, which is the first
[26:01] thing that uh it's the original name of
[26:03] C++ called C with class because that's
[26:04] what's going to be. It's going to be
[26:05] taking simul type system and putting
[26:08] something like that into uh into C. And
[26:10] the reason for that is pretty obvious.
[26:12] He goes to Bell Labs and C would be like
[26:14] a lingua frana there probably, right?
[26:15] Because they're the people who make
[26:16] Unix. They're the people who make C like
[26:18] the people uh who are at Bell Labs, the
[26:20] people making these technologies. So he
[26:23] is tasked when he gets to Bell Labs with
[26:25] doing the same sorts of distributed
[26:26] systems analysis that he was trying to
[26:28] do at Cambridge. Uh he's he's trying to
[26:30] do those things for Unix. He wants to
[26:33] analyze certain behaviors of it and that
[26:34] sort of thing. And he finds like the
[26:36] same exact things. He would like to
[26:37] write in something like Simula. He
[26:39] doesn't want to have the same disaster
[26:40] that he had where he had to rewrite
[26:41] everything in BCPL. So he's like, could
[26:43] I take C, add classes to it, and get the
[26:46] best of both worlds? Something that
[26:48] actually runs and doesn't fall over,
[26:50] right? But that has some of these
[26:52] features that I've been enjoying. And so
[26:54] that's what he's doing. And he's doing
[26:56] it for the same reason, right? That sort
[26:57] of modularity and concurrency analysis
[27:00] kind of stuff. He's trying to figure out
[27:02] how these things work and run
[27:03] simulations of them. Same exact thing is
[27:05] happening and it's happening over again.
[27:07] And what he kind of complains about with
[27:10] C if you didn't have these things, some
[27:12] of it's a little confusing. Like he
[27:13] talks about the fact that he says like
[27:15] all program parts can poke into all of
[27:17] the memory. And like C++ doesn't really
[27:19] change that, but I think he's just kind
[27:20] of talking about like, you know, private
[27:22] declarations, right? He's just like,
[27:24] well, you know, I I obviously I don't
[27:25] think you can stop programs from poking
[27:27] into the memory by putting private on
[27:28] it, but it will stop programmers from
[27:30] typing it into the compiler. And that's
[27:31] sort of the same thing, right? And where
[27:34] that comes from, this sort of idea that
[27:35] we're going to protect things that
[27:37] actually comes again from his
[27:38] distributed systems sort of OS thinking
[27:41] background because he's looking at
[27:43] hardware and he's looking at things like
[27:45] virtual memory and protection that you
[27:47] get between processes and those sorts of
[27:49] things and he's saying that's kind of
[27:50] what I want for programming like I don't
[27:52] really want to make those mistakes where
[27:55] I access the private part of things, you
[27:57] know, I want to be able to wall those
[27:59] off. And he's thinking about actual
[28:01] hardware, computer hardware. That's
[28:02] where that idea comes from. Again, it
[28:04] doesn't even come from working on large
[28:06] teams or anything like that. It comes
[28:07] from thinking this might be a nice
[28:08] feature. Just like the computer stops
[28:10] it, right, from happening, the compiler
[28:13] could stop it from happening. And that's
[28:14] where const comes from too. It comes
[28:16] from an OS metaphor. He's thinking about
[28:19] whether or not files have write
[28:21] permissions to them, right? Are they
[28:23] readon or are they writable? That's what
[28:25] const is to him. That's where he thinks
[28:27] thinks about it first. So again, all
[28:29] these things come from a very different
[28:30] place than what you would think if you
[28:32] didn't go back and read the historical
[28:33] documents. Uh and by the way, these
[28:35] aren't hard to find. Like these these
[28:37] just come from the D& which is a very
[28:38] popular book that he wrote. Uh that's
[28:40] just collection of his papers, right? So
[28:42] a lot of this a lot of the stuff in the
[28:43] first part of the talk you don't have to
[28:44] dig that hard for. All right. So anyway,
[28:48] we get sort of a second wrinkle at this
[28:50] point. And what happens when he starts
[28:53] using this stuff is it's important to I
[28:57] shouldn't really say what starts
[28:58] happening. Let's say one of the things
[29:00] he does is he uses the inheritance that
[29:03] he puts into this sort of C with classes
[29:06] because he's just going to do the same
[29:07] thing that was happening in Simula. He
[29:09] uses that inheritance in a way that
[29:10] would generally be you know frowned upon
[29:13] even by him today. And that is to do
[29:15] things like implement a linked list and
[29:16] reuse it. So what he does is he says
[29:19] okay I'm going to take a block that's
[29:21] like the linking part of things and I'm
[29:23] just going to inherit stuff from it so
[29:25] that all the things that inherit from it
[29:26] can go in a list right now he would
[29:28] never say to do that today he would say
[29:30] use a template or something like that
[29:31] like a parameterized type right so but
[29:33] it's important to remember at that time
[29:35] this was a thought and this thought
[29:37] actually does come from simul as well
[29:38] we'll get to that later but so it's
[29:40] important to say in addition to the
[29:42] modeling part they're using inheritance
[29:45] for the purpose of code reuse produce
[29:47] even if it really doesn't have much to
[29:49] do with anything. That's sort of an
[29:50] adjunct split. I just want to include it
[29:52] here so that you understand all of the
[29:53] things that were being thought about
[29:54] with inheritance at the time when it was
[29:56] actually being put into more mainstream
[29:58] languages. So that's what he was uh one
[30:00] of the things he was doing with it in
[30:01] addition to the domain modeling part
[30:02] which is more of a direct mapping. Okay.
[30:05] And you can see him here criticizing it
[30:07] just to hammer this home. He doesn't
[30:09] think you should do that anymore. and he
[30:11] said as much in parameterized types for
[30:13] C++ which is where he started to talk
[30:15] about templates as soon as templates as
[30:17] soon as he got his answer to how we were
[30:19] going to do these sort of things. Uh as
[30:22] soon as he got like a parameterized type
[30:23] model because that wasn't new to C++
[30:25] there were languages like ADA and clue
[30:27] and stuff that had that in there. He
[30:29] started to say okay C++ has never had a
[30:31] good way to do this because you had to
[30:32] do the inheritance thing. That's not
[30:33] fabulous. Parameterized types are the
[30:35] way to go. So he knows that too. It just
[30:36] takes a while to get there.
[30:39] Okay. So that's kind of the end of it
[30:42] and virtual functions come in a little
[30:44] bit later. The first version of C with
[30:46] classes when he's first starting on it
[30:48] doesn't actually have virtual functions.
[30:50] He eventually does put virtual functions
[30:52] in. And when he does, this is what he
[30:53] says about it. He says it was borrowed
[30:55] from Simula and presented in a form that
[30:56] was intended to be make it simple and
[30:58] efficient. So he was thinking primarily
[31:01] about I I want something kind of like
[31:02] what Simula has for this ability to call
[31:05] functions without knowing the type on
[31:06] them. uh but I want to make sure it's
[31:08] very fast because that was a concern
[31:09] that he always had again because of the
[31:10] disaster he had experienced uh directly
[31:12] with Simula. So again, reflecting on
[31:15] this, it's totally different from what
[31:19] you would think if you just read like
[31:20] the capsule summary. Like he's not
[31:23] talking about large teams still. He's
[31:25] talking about literally we're just
[31:27] working on this thing. I'm using
[31:29] inheritance for some reuse of code and
[31:32] I'm using it to directly model the
[31:34] compile time, you know, at a compile
[31:35] time and using it directly model the
[31:37] actual domain that I'm working in which
[31:38] happens to be distributed computer uh
[31:40] distributed systems analysis yet again.
[31:43] So we have to jump at this point because
[31:47] that's pretty much all we can get out of
[31:48] C++. I mean that's you kind of got the
[31:51] picture now. Everything else is like
[31:52] after the fact. Everything else is post
[31:54] talk. Anything else about C++ was people
[31:56] making stuff up after that or adding
[31:58] things to it after that. But that's
[31:59] where it comes from. So if we want to
[32:02] actually know where these ideas started
[32:03] from, we've got to go back to Simula.
[32:06] We've got to say, well, okay, if all
[32:07] this stuff came from Simula and him
[32:09] using Simula, well, where did it come
[32:11] from in Simula? like did they just make
[32:12] it up? And Simulator originally comes
[32:15] from something called the Norwegian
[32:16] Computing Center. I mean we we are here
[32:18] very close to Norway I suppose. So some
[32:20] of you may have known this place. I
[32:22] didn't really know anything about it
[32:23] until I read that like you know was
[32:24] reading up on Simula and like okay
[32:26] there's this place. It's a quasi kind of
[32:28] private public uh institute for doing
[32:31] computing research and it's it's in
[32:33] Oslo, Norway. And in 1962,
[32:36] these saucy gentlemen right here, uh,
[32:38] and I'm I'm apologizing like Sweden is
[32:42] the worst place to give this talk
[32:43] because now I have to pronounce their
[32:45] names in front of people who probably
[32:46] know, uh, Norwegian pronunciation very
[32:49] well. And so I'm going to butcher it and
[32:52] I apologize. It's Oly Johan Dal. Maybe I
[32:56] can pronounce that correctly. And
[32:57] Kristen Nygard. And you already know
[32:59] Kristen Nigard's name because this is
[33:01] the person who Bjanna Trustup learned uh
[33:04] the simula from originally. He was you
[33:06] know he interacted with him a lot when
[33:08] he was uh at his previous university
[33:10] before Cambridge. So these are the folks
[33:12] who make simul
[33:14] kind of like the masterminds behind it.
[33:17] And the first reference we have to it is
[33:19] in private correspondence that has now
[33:21] been published uh from Nygard to a
[33:24] another person who was working on
[33:26] operations research. And these folks
[33:28] operations research if you don't know
[33:30] what that is, it's when you look at how
[33:32] systems are behaving to in order to
[33:34] optimize them basically. So you can
[33:36] think about things like we're you know
[33:38] we're trying to plan how you know the
[33:40] military is going to organize some
[33:41] things like what is their process going
[33:42] to be and we want to maximize the
[33:43] throughput of like how we're
[33:44] manufacturing this thing or how we're
[33:46] going to load planes onto an aircraft
[33:47] car. I don't know anything like that. A
[33:49] lot of it's military because that's
[33:50] where the funding comes from. But it's
[33:51] for anything really. it's also in
[33:53] business operations research uh things
[33:55] things like the simplex algorithm if you
[33:56] ever heard of that that's operations
[33:57] research etc etc so anyway he says like
[34:01] I got this idea what I'm going to do is
[34:04] I'm going to make this language that
[34:05] makes it very easy to describe one of
[34:07] these systems and then what I will do is
[34:11] use it to describe these problems in a
[34:13] way that allows it to do the simulations
[34:16] automatically so it's like almost like a
[34:18] scripting language for system simulation
[34:21] and if you Look, this is some code you
[34:24] can find when they talk about the
[34:26] history of it. Uh, this is in 1963. The
[34:30] simul language would have looked like
[34:31] this. It's one of the earliest snippets
[34:32] I could find. And so this is not the way
[34:35] the final simul look. This is sort of
[34:37] how they started out. And you can see
[34:39] what it essentially is. And you don't
[34:41] need to understand exactly what's going
[34:42] on in this for the talk. So I'll I'll
[34:44] spare you the details. But essentially
[34:46] what you're doing is you're setting up
[34:47] these various things like customers and
[34:49] stations. It's like things we're we're
[34:51] imagining like entities moving between
[34:53] parts of a system and we write little
[34:55] pieces of code that's like how they will
[34:57] be processed when they get there. Like
[34:59] will this person you know they'll be
[35:00] held for a little bit of time and then
[35:02] we'll check to see if they've paid the
[35:03] fee and if they've paid the fee we'll
[35:05] send them to this station. If they
[35:06] haven't paid the fee we'll send them to
[35:07] this other one. And the idea is you just
[35:09] describe that system this way. You run
[35:11] the simulation and it presents you with
[35:12] a bunch of statistics so you can kind of
[35:14] see like okay this is where the
[35:16] bottlenecks were or things like that you
[35:17] know
[35:19] and that was very successful. They
[35:21] eventually released a thing called
[35:22] stimula 1 which was the first sort of
[35:24] more widespread version of this thing.
[35:26] It was people loved this. They could do
[35:27] their system analysis this way. But uh
[35:30] Nygard and D were thinking in their head
[35:32] like we really like this thing and we
[35:34] think it has more it has possibility to
[35:36] be bigger than what it is. Powerful just
[35:39] what we had in that first version. So
[35:41] they start to make a new version which
[35:43] eventually goes on to be called Simul
[35:44] 67. And this is like it's like Windows
[35:46] 95 right at this point in time people
[35:48] are starting to name languages where you
[35:51] append the year of the language after
[35:52] the language. So we have things like
[35:54] Alol having that or Cobalt 60 is the
[35:57] version of Cobalt that was first
[35:59] introduced in 1960, right? And so that's
[36:02] what Simul 67 would eventually be. And
[36:04] they're trying to figure out what
[36:05] they're going to do uh for this new
[36:07] version. And what happens is they're
[36:10] thinking about code reuse. They're like,
[36:13] we don't really like we have to rewrite
[36:14] things a lot of times and we're trying
[36:16] to figure out some way that we could get
[36:18] some of this reuse in there. like we
[36:20] want to reuse these things and it's not
[36:22] really working out very well for us.
[36:24] They're looking for a solution to this
[36:25] and they're not really finding one. But
[36:28] eventually when they're thinking about
[36:30] this problem, they're saying, "What if
[36:31] we have like a bridge with a toll booth
[36:33] on it and we've got cars going across
[36:35] it?" And they might be either trucks or
[36:37] buses. What could we do so that we could
[36:40] just write this once and have it work
[36:42] for both the trucks and the buses so we
[36:44] don't have to like duplicate all the
[36:46] stuff we said for trucks and buses?
[36:47] That's what they're thinking of. And
[36:49] this is not me saying this was this is
[36:50] them saying this is what they were think
[36:52] this is what they were trying to solve.
[36:54] Literally this is what they were trying
[36:56] to solve when they came up with classes.
[37:00] And here is what those classes look
[37:01] like. You can see up at the top there
[37:03] it's defining link class car. The link
[37:06] is a thing where they have this linked
[37:08] list sort of superass that they're
[37:10] deriving from and they're going to have
[37:11] a car. Then they're going to say
[37:12] underneath cars they're going to derive
[37:14] a car class truck and a car class bus.
[37:16] There's different kinds. You can see
[37:18] load and capacity are like two different
[37:19] data members that those have. Okay. So
[37:22] in this one snippet we can see both
[37:25] things that not only they are about to
[37:29] do but that bjarnstrip is about to do as
[37:32] well. We are using this for reuse. We
[37:35] are deriving from a link class to get
[37:37] its functionality not because we think
[37:39] that we are like a link in the domain
[37:41] model. But then mostly what we're doing
[37:44] is following the domain model with our
[37:46] classes. it is car and underneath it is
[37:49] truck and bus exactly like would
[37:52] eventually be promulgated as how to
[37:54] design oop systems with those
[37:56] hierarchies that I was talking about. So
[37:58] that's what it looked like and they
[38:01] literally said hey this now allows us to
[38:04] quickly just say this thing is a link
[38:05] and then it can go in lists. Awesome.
[38:09] Now you'll notice they didn't actually
[38:10] talk at this time very much when they
[38:12] were counting the history and I guess I
[38:14] shouldn't say you'll notice. I noticed
[38:16] because I had to read the whole thing.
[38:18] They don't really talk about the virtual
[38:19] function part at the outset, right?
[38:22] They're kind of talking about just this
[38:24] reuse part. That's mostly what they're
[38:25] concerned about, but they do eventually
[38:28] care about that virtual part because
[38:29] once they do this subclassing, they're
[38:31] like, hm, we want to have ways that the
[38:34] subasses can do things in addition to
[38:36] what the parents doing. And that's where
[38:38] the idea from virtual functions comes
[38:39] from. They say we have these operations
[38:42] that we were defining, you know, things
[38:43] like what that queuing behavior was
[38:45] going to be that I showed on the
[38:46] original slide from, you know, Simula
[38:48] back in 1963. And they're like, we want
[38:50] to have those operations be modified
[38:53] based on whether this, you know, car is
[38:55] a truck or a bus and things like that.
[38:57] So that's what happens. Now, if you look
[39:01] at how this had to actually work, it
[39:04] works the same way that primitive code
[39:06] reuse works. If you wanted to use it
[39:09] today, if you want to use inheritance
[39:10] for things like links, it worked exactly
[39:12] the same way. They literally had the
[39:14] sort of class hierarchies. I can see in
[39:15] the middle there, class sim set and sim
[39:17] set class simulation. That's basically
[39:19] saying like look, all of this stuff is
[39:21] going to be derived from like linked
[39:23] list holder. That's what simis would be
[39:25] like. Like I'm a person who holds link
[39:26] lists and then we're going to derive the
[39:28] simulation from the thing that holds
[39:29] link lists. That way it can use that. So
[39:32] it's almost like a library like they're
[39:33] using inheritance like a library here as
[39:36] well as the domain model which is under
[39:37] it. So again that same double duty. All
[39:40] right. So again just a hammer at home.
[39:44] Nothing about teams, nothing about
[39:46] architecture, none of this stuff, right?
[39:48] It's all about trying to solve a code
[39:51] reuse problem and then something falls
[39:53] out of that. No analysis is done of any
[39:55] of the things that you would normally
[39:57] say if you were trying to promote the
[39:59] use of domain modeling via those class
[40:01] hierarchies. Right? That's not what's
[40:03] happening.
[40:05] So
[40:07] this is where we actually got compile
[40:09] time hierarch that matched the domain
[40:11] model because simula actually did have
[40:13] encapsulation. You couldn't refer to
[40:15] things outside of the entities like that
[40:17] very much. And so it kind of did have
[40:19] the beginning of that. It wasn't as
[40:21] rigid as C++ as we'll see. But that's
[40:23] effectively what it was.
[40:26] So
[40:29] I don't know how to summarize all of
[40:30] that that we just saw. Basically what
[40:32] I'd say is effectively what we sort of
[40:35] were seeing is this came out of sort of
[40:38] an approach to templates that wasn't
[40:40] very good. Like that's that's sort of
[40:42] what happened. And it's not their fault
[40:43] cuz I mean they're in the wilderness,
[40:44] right? Like nobody knows any of this
[40:46] stuff. We take for granted all the
[40:47] things we know today. They don't know
[40:49] any of this. They have to invent
[40:49] everything. But that's really what they
[40:51] almost wanted if you had handed them
[40:53] templates at the time they were trying
[40:55] to do this. They may never have invented
[40:57] this class concept at all because they
[40:59] they just wanted a link list. they just
[41:00] wanted a way to say I have list of
[41:01] things going across right or whatever.
[41:03] So that's sort of where they had started
[41:05] and they just happened to come up with a
[41:06] virtual function thing which by the way
[41:08] is useful for stuff. I'm not trying to
[41:09] suggest that it isn't but that was sort
[41:11] of a byproduct of what they were trying
[41:12] to do which was just make a list class
[41:14] they could reuse kind of. All right so
[41:18] that's the end. That's the entire story.
[41:19] Now you know where everything came from.
[41:22] I mean, of course, if you only want to
[41:24] do sort of the capsule version, that's,
[41:26] you know, again, sort of the this the
[41:27] Wikipedia version of it,
[41:30] but you have to kind of ask the
[41:31] question, I mean, we know that they did
[41:34] those things, but like where did they
[41:36] get the idea for those things? I mean,
[41:38] that's usually how I approach things
[41:40] anyway, right? I'm like, after I find
[41:41] out that like someone got the idea from
[41:43] someone, I'm like, well, do we know if
[41:45] that guy got the idea from someone? Cuz
[41:47] I want to know about following it the
[41:49] whole way back, right? So, that's the
[41:51] end. If you just use a capsule Wikipedia
[41:53] summary again, you'd kind of get
[41:55] something like that out of it. What you
[41:57] probably wouldn't get is this stuff. So
[42:02] when you actually go digging in here and
[42:03] you pay attention to every little thing
[42:05] and every time you come across something
[42:07] but someone mentions, you're like,
[42:08] "Wait, what?" And then you go try to
[42:10] pull the papers that they're actually
[42:12] referencing, you start to find out a lot
[42:14] of other stuff. So if we keep pulling
[42:16] this thread, what we find is the idea of
[42:19] subclassing is not credited to uh Nygard
[42:23] and Dah. They credit it to somebody
[42:26] else. C actually the guy who
[42:30] invented quicksort.
[42:32] That's who they say this idea of
[42:34] subclassing came from. They don't claim
[42:37] to have invented it. They claimed to
[42:38] invented a version of it that was
[42:41] derived, pun intended, from work,
[42:45] right?
[42:46] And this is the paper that they're
[42:48] referring to. This is the paper that I
[42:49] believe they would have read, although
[42:51] I'm not sure exactly which version they
[42:52] read because different versions were
[42:53] circulated. And there's actually uh sort
[42:55] of a further comments one happens after
[42:57] this. But they would probably be aware
[42:58] of all of this because academics are
[43:00] always very good, right, at sharing
[43:02] their information this way, putting out
[43:03] publications. I mean, it's it's their
[43:05] it's the thing that is cred for them,
[43:08] right? Like your papers are your cred.
[43:09] So you're reading papers by other
[43:11] people. You're writing your papers. So
[43:13] they were uh they read this paper for
[43:15] sure. Which version exactly? I I
[43:16] couldn't tell you. But this is the
[43:18] paper. And here's what is talking
[43:20] about in this paper. He says, "All
[43:23] right, we have in the real world, and I
[43:26] want to underline that because it's like
[43:28] compile time hierarchy that matches the
[43:30] domain model, right? In the real world,
[43:33] we have objects that we want to model
[43:35] and they have different versions of
[43:37] things and we want to model that sort of
[43:39] discrimination that's happening there in
[43:41] the subasses. And so he gives the
[43:43] example of an algebraic expression. He's
[43:45] like, if you look at an algebraic
[43:46] expression, I'm trying to model that. I
[43:47] want to represent that in the computer.
[43:48] I might say I have an algebraic
[43:49] expression and then I have these
[43:51] different things that are types of
[43:52] algebraic expressions, right? And he
[43:54] says constants, variables, diatic
[43:56] expressions, right? He's trying to model
[43:57] language. And by the way, this happens a
[43:59] lot. uh I don't really cover it much in
[44:01] this talk because it's not relevant but
[44:02] you'll see a lot of people this time
[44:04] were working on things like how do we
[44:05] parse stuff right so sort of thinking
[44:07] about how do we parse language how do we
[44:08] parse computer languages how we parse
[44:10] human languages are thinking about this
[44:11] kind of thing all the time it's like
[44:13] what if I want to represent an equation
[44:15] how am I going to do it right and he's
[44:16] saying what about these subasses and he
[44:18] would literally write it just like this
[44:20] so as we can see
[44:23] nyard and doll were not lying they 100%
[44:25] did get this idea from that it looks
[44:28] almost exactly like theirs down to the
[44:30] syntax. You can see that he's saying I'm
[44:32] going to have an expression. Here are
[44:32] the subasses of the expression. It's
[44:34] going to be constant and variable,
[44:36] right? And so this is what NAL read. And
[44:40] they were like, oh wait a second, what
[44:43] if we just had like our cars and trucks
[44:46] and buses under them and we could just
[44:48] use the car and then we put the car
[44:50] across the bridge. Okay, that would
[44:52] work. Wait, but we don't have to stop at
[44:54] the car. We could make something above
[44:55] the car that's like things that are in a
[44:58] list of stuff and then we could use it
[44:59] for everything. Doesn't even have to be
[45:01] the bridge. Holy cow, dude. Like, thank
[45:04] you. Thank you, Tony. Uh, so anyway,
[45:07] yeah, Anthony. They call him Tony
[45:08] because I was he didn't go by Anthony.
[45:11] Anyway, sorry thing I didn't introduce
[45:13] ahead of time. It's just up here because
[45:15] I've been reading this stuff for, you
[45:16] know, I don't know, months at this
[45:17] point. Anyway, so
[45:20] when he presented this in this paper, it
[45:24] doesn't stop there. And this I found so
[45:26] interesting. And we're starting to get
[45:28] into stuff now where like I had never
[45:29] heard before. A lot of this stuff when I
[45:31] diged into it, I was like, how come
[45:33] everyone doesn't know this because it's
[45:35] super cool. When he presented this
[45:37] paper, or I shouldn't say presented this
[45:38] paper, when he wrote this paper, he
[45:40] included discriminated unions in it.
[45:42] Tagged unions, whatever you want to call
[45:44] them. There's FP people out there in the
[45:45] audience are going to scream at me for
[45:46] using the wrong term, but you know what
[45:48] I'm talking about. Something that has a
[45:49] type in it and then subasses inside it.
[45:51] And you don't know which one you have
[45:52] until you look at the type. And then you
[45:54] can, you know, use whichever part makes
[45:56] sense for that type. And this is a super
[45:58] powerful programming. I use it all the
[46:00] time. And I think it's one of the best
[46:01] programming tools you have for things
[46:03] like dynamic polymorphism. I absolutely
[46:05] love it. It's in this paper in 1966,
[46:08] right? A long long time ago.
[46:12] And this is his way better than anything
[46:16] I get to use today in C++
[46:18] thing he suggested for what you would do
[46:22] when you wanted to use one of these. He
[46:24] said it's a switch statement which of
[46:26] course you know wouldn't been called a
[46:27] switch statement at that time but it's
[46:28] basically a switch statement that says I
[46:30] want to use this object and I'm going to
[46:31] tell you what each type you know which
[46:34] whatever the subtypes might be. I'm
[46:35] going to give you a different block of
[46:37] code to run depending on which one they
[46:39] were. Right? Again, functional
[46:40] programming, I believe, would really
[46:42] like something like this, right? It's
[46:44] doing that discriminated union thing.
[46:45] And furthermore, he gets the fact that
[46:48] this adds type safety and prevents
[46:50] errors. He gets the fact that the code
[46:52] that would come after the then
[46:54] statements can now safely refer to the
[46:56] subtypes because, you know, you've
[46:58] checked what the type actually was. And
[47:00] he says that right in the paper. So, he
[47:04] totally got it. He knew way better than
[47:07] any of the knock-on languages. uh sort
[47:09] of you know I guess from C++ on he knew
[47:12] way better even at that time how cool
[47:15] discriminated unions would be if you had
[47:16] the right language constructs to work
[47:18] with them in a type- safe way. So I
[47:21] thought that was super duper awesome.
[47:24] Now
[47:26] if you think about it if this was in the
[47:29] paper and similar read the paper and
[47:32] that's how they created simula was or
[47:34] the class concept in simula and the idea
[47:36] of subclass simula and then you know C++
[47:40] came out of simula well why don't we
[47:42] have like why wasn't this a first order
[47:44] feature like where did the discriminated
[47:46] union part go and the answer is well
[47:49] nyard doll actually put it in it was
[47:52] called inspect
[47:53] So, Simula actually had this. You didn't
[47:56] have to use virtual functions. Simula
[47:58] was way better about that. When Strrip
[48:02] went to do his classes, he took it out.
[48:05] He thought that discriminated us were
[48:07] bad because they broke modularity,
[48:09] right? It's because now someone from the
[48:12] outside can tell what class you are. So,
[48:15] we lost out on one of what I consider
[48:17] would be one of the most important
[48:19] features I would use in C++ every day
[48:22] because it got removed when Simula was
[48:25] playing telephone with C++.
[48:34] All right. So, there you go. That's
[48:36] where the concept actually comes from.
[48:38] Right? This is it's this paper by you
[48:42] know Anthony a s he's sir now by
[48:44] the way he he he he's he's been kned I
[48:46] believe right um and again not a single
[48:52] part of it there's no no hint at all
[48:54] that any of this is really about compile
[48:58] time hierarchy stuff or about large
[49:00] teams or about any of the things we
[49:02] talked about today. It was literally
[49:03] like, hey, I might have a record that
[49:06] wants to have a type field and it would
[49:07] be cool if I could just switch on the
[49:09] type field and do different things based
[49:11] on it. How about that? Right? And that's
[49:14] what I would have wanted. So, we had
[49:15] that already back when this paper
[49:18] circulated uh in 1966. So, really the
[49:22] whole string is about us getting a
[49:24] really bad version of discriminated
[49:26] unions. We had them already and now we
[49:29] don't have them. To this day, I don't
[49:31] even know a standard variant really
[49:33] works as well as this thing would have,
[49:35] right? And we could have had it from day
[49:38] one if someone had just believed that
[49:41] this was good.
[49:43] All right, so that's the actual end. Uh,
[49:46] we've gotten back to kind of kind of the
[49:48] point of the first part of the talk.
[49:54] There's another half because it goes way
[49:56] further back than that, but I want to
[49:58] give everyone a chance to kind of
[49:59] stretch out. So, I don't know. Can we
[50:01] take a break? Where where is Sam? Can we
[50:03] take a break for a few minutes?
[50:04] >> Yes. How long do you want?
[50:06] >> I don't care. I can keep going if you
[50:08] don't want, but I figured Yeah, stretch.
[50:10] >> Let's go to 25.
[50:12] >> Okay. I'll see everyone back here
[50:14] whenever that is at 25.
[50:17] [Applause]
[50:25] Okay, so as you saw in the first part,
[50:29] you come to the end a lot of times, but
[50:32] then it's like, well, you know, is it
[50:34] really the end? If you keep digging,
[50:35] turns out you didn't really get to the
[50:38] actual meat of, you know, the the origin
[50:41] story. You didn't really get to the part
[50:42] where I don't know, I'm bad with comic
[50:44] books, but like, you know, Bruce Wayne
[50:45] and the Falling Pearls and the Joker and
[50:47] that kind of stuff. We actually gotten
[50:48] back to that scene and that's the scene
[50:50] that everyone wants to see in the movie.
[50:51] It's like how did he become Batman? So,
[50:54] what we're going to do here in the
[50:55] second half, I promise there's only this
[50:56] only it's one more half. There's two
[50:58] halves. I'm not going to psych out
[50:59] again.
[51:01] We're going to do here is we're we're
[51:02] going looking for Batman, right? So, we
[51:05] left off. We've got this paper on record
[51:08] handling by Uh, right. famous for
[51:12] quicksart like I said one of the the
[51:14] fathers of computer science
[51:17] and the interesting thing is and this
[51:19] was really hard to figure out but I was
[51:22] trying to like where did he get the idea
[51:25] like did he come up with the idea was he
[51:27] sitting around what was he working on
[51:29] right and it was really hard to find
[51:31] this I wish that I could find a document
[51:33] where he talks about it if any of you
[51:35] out there ever find a document because
[51:37] you know I did the the most research
[51:39] that I could do in the time that I
[51:41] uh to figure out where these things came
[51:42] from. But I'm sure I missed something
[51:45] somewhere. So if you're going to
[51:46] actually figure this out, I would love
[51:47] to see it. But after a lot of digging, I
[51:50] figured out something pretty
[51:51] interesting, which was that actually
[51:56] there was this committee that was
[51:58] supposed to alming
[52:01] language that was very popular at the
[52:04] time. It was in use since the the early
[52:06] 60s, actually. Actually, it might have
[52:08] even been before that. I don't remember
[52:09] cuz it's not that relevant to to this
[52:11] particular timeline. But what they were
[52:14] going to do is much like Simula had an
[52:16] update from Simula 1 to Simula 67 here
[52:19] there's going to be an update of Alol up
[52:21] to this new version that would
[52:22] eventually be called Al Gal 68 and the
[52:25] people who are working on this it's like
[52:27] a who's who of like computer science
[52:29] fame right so horror is on this and and
[52:32] so are a lot of other people like
[52:33] Nicholas Worth and that kind of people
[52:34] like people the person invented Pascal
[52:36] or created Pascal right so on this
[52:39] committee there was another guy and his
[52:42] name was Douglas T. Ross. And this is a
[52:46] name that I had never seen mentioned
[52:48] ever before. I have no idea who this guy
[52:50] is. And I'm like, wait, what? And oop,
[52:52] sorry. And when was talking about it was
[52:56] like oh you know in some private
[52:58] correspondence because Alan Blackwell
[53:00] and Carrie Roden not really a part of
[53:01] the story but they're like we talked to
[53:04] her privately about where we got those
[53:06] ideas and he said that they actually a
[53:10] lot of them came from this guy named
[53:11] Ross who he had conversations with when
[53:13] they were on the committee. And I'm like
[53:16] okay so what's this about? And Ross had
[53:20] this thing he called a plex, which is a
[53:23] record-l like data structure. And
[53:24] apparently this was something that
[53:26] really influenced
[53:28] uh horror's record handling paper, which
[53:30] would eventually go on to in you know
[53:33] create the rest of the chain that we
[53:34] just went through. So that's one thing.
[53:37] And another thing is if you look at the
[53:39] other branch, the branch that I'm not
[53:40] really covering very much in this talk
[53:42] because again we don't program in small
[53:44] talk these days, right? The closest
[53:45] thing you would get is maybe something
[53:46] like object Objective C if there are
[53:47] some still people out there using
[53:48] Objective C you know like Apple was
[53:50] using that for a little while. So
[53:52] Objective C kind of came from a small
[53:53] talk background as well. So but it's
[53:56] another huge branch of object
[53:58] programming. Small talk was very
[53:59] important. It's influential at least in
[54:01] the research or in the understanding of
[54:02] oop right it was a very pure oop
[54:04] language. It it pushed oop a lot further
[54:06] than a lot of the other languages by
[54:07] saying everything is going to be
[54:08] object-oriented and that sort of thing.
[54:10] And of course it invented the term
[54:12] object oriented. So it's everything's
[54:13] going to be like small talk which is
[54:14] what objorinted was right if you look at
[54:17] what Alan K talks about for his
[54:20] inspirations like where did he get his
[54:21] ideas from small talk he list some
[54:24] things and there's some like the
[54:25] burough's B5000 and this file system
[54:27] from an air force base that had to do
[54:30] mostly with dispatches we could go into
[54:33] that in the Q&A if anyone cares. But one
[54:35] of the things he talks about is Simula
[54:37] which we've already covered and the
[54:39] other thing is Sketchpad. He talks about
[54:42] sketchpad all the time. This was a huge
[54:44] hugely impactful thing for Alan K. And
[54:47] Sketchpad was like this drawing program,
[54:50] right? I was aware of Sketchpad. I mean,
[54:52] maybe some of you are aware of
[54:53] Sketchpad. It's pretty famous. You can
[54:54] look up demos of it on YouTube, for
[54:56] example. So, we've got this Ross guy
[54:59] that I want to look into more. I'm like,
[55:01] what's going on? And then we got this
[55:03] Sketchpad thing. And I'm like, hm, I
[55:05] think I remember Sketchpad, but I don't
[55:07] really know why that would have inspired
[55:08] Alan K to do object. So, I'm going to
[55:10] look into this more. I want to see just
[55:12] make sure I've got the whole story
[55:13] before I really say the end like I fake
[55:16] did in part one. So, let's go back even
[55:19] further. 1952. Now, there's this place
[55:22] called the Servo Mechanisms Laboratory
[55:24] at MIT, which is kind of an amazing
[55:27] name. Um, I would love to be able to
[55:29] tell people that I worked at a servo
[55:31] mechanisms library, uh, a laboratory
[55:34] rather. But this fellow right here, that
[55:36] is Douglas Ross, who now I know exactly
[55:38] who he is and what he did. He goes there
[55:42] and he's first on the job in 1952. He
[55:45] gets to this laboratory and what their
[55:47] sort of whole mission was, this was
[55:49] Department of Defense, United States
[55:51] Department of Defense research stuff.
[55:53] What they were trying to do is build a
[55:56] system where someone from like, you
[55:59] know, the Air Force could describe a
[56:01] part that they were going to try to
[56:03] manufacture and the computer would just
[56:05] make it. It's almost like the birth of
[56:07] like 3D printing. And they actually did
[56:10] demos of this. They had stuff working
[56:12] where you could like type in a
[56:13] description of an ashtray in like the
[56:15] sort of pseudo language that they had
[56:17] that was meant to be kind of more uh
[56:19] it's sort of, you know, uh almost like
[56:21] in a Gracehopper sense, right? like
[56:23] something that's sort of we're trying to
[56:24] get closer to human language but it's
[56:26] really not human language because they
[56:28] don't have the ability to parse that yet
[56:29] right I mean until a large language
[56:31] models we didn't have the ability to
[56:32] parse that right so when you look at
[56:35] something like this what they're trying
[56:37] to do is say pseudo language and our
[56:39] milling our automated milling system
[56:41] produces like this object out of it
[56:43] right and they actually have working
[56:45] it's it's not entirely they've got it
[56:47] working they have uh instances of
[56:49] objects you can actually look at that
[56:50] they made so they're they're
[56:51] accomplishing this as Well, and you have
[56:54] to remember how early this is. 1978 is,
[56:56] you know, I date these by when the
[56:57] person's talking about it. This is the
[56:59] 1950s that they're doing it, right? So,
[57:02] they're working on this this simulation
[57:04] stuff that I'm sorry, this uh this
[57:05] processing stuff and this where they're
[57:07] trying to take language and turn it into
[57:08] uh sort of CAD, right? The birth of CAD.
[57:12] And just to show you how early this is
[57:15] in the thinking about what's going on in
[57:17] computing, cobalt is generally like
[57:19] again in the kind of uh loweffort
[57:22] Wikipedia search version, cobalt would
[57:24] be the first thing you'd see referenced
[57:26] as having things like record-l like
[57:28] strrus, right? Like we all take a
[57:29] strruct for granted where like a strruct
[57:31] is like the simplest possible thing,
[57:32] right? It's not doesn't have inheritance
[57:34] or it doesn't have uh virtual function
[57:36] calls or any of that stuff. we would
[57:38] just say, you know, if we're just
[57:38] talking about a bare strct, a basic
[57:40] vanilla strruct, that doesn't really
[57:42] exist. Like no one's thought about that
[57:45] really. They have sort of an idea of
[57:47] data records that comes more from like
[57:50] data processing, like the old IBM sense
[57:52] of the term. So they do have an idea of
[57:54] like more of like the database version
[57:56] of like I've got some fields that
[57:58] comprise like a record but people aren't
[58:01] really thinking like when I program
[58:04] the computer program is also going to be
[58:07] written in terms of records that it's
[58:09] using purely for computation not to
[58:11] store a particular piece of data like on
[58:14] magnetic tape or something like this
[58:16] right but it's just purely an artifact
[58:19] of the implication of this program I've
[58:21] defined other records
[58:23] They're not thinking about that. And
[58:25] even in this in 1960 when this was uh
[58:28] printed, this first version of Cobalt,
[58:31] even in that 1960 time frame, this
[58:34] Cobalt didn't really have that. All of
[58:36] its record stuff was pretty much still
[58:37] about data on tape kind of things. It
[58:39] was it was in memory as well when you
[58:40] had a mirror of one, but it wasn't no
[58:42] one was thinking really about that as
[58:44] far as I could tell. They're just think
[58:45] of it as storing data. Now pedance will
[58:48] say that plan calcul
[58:51] has this but it was a purely theoretical
[58:53] language just written down on paper. It
[58:54] was an early German programming
[58:56] language. It's very forward thinking so
[58:58] I don't want to disparage it at all but
[59:00] it doesn't count if you just sort of
[59:01] wrote down well maybe we'll have this
[59:03] way to like put multiple things. It's
[59:05] like no matter how rigorously define it
[59:07] on paper you don't get credit unless
[59:09] you've actually got this working and
[59:10] you're actually programming making
[59:11] programs in it that you run right. So
[59:14] really it's it's kind of not there at
[59:16] the time. So what people are actually
[59:18] thinking about is this right? Lisp is
[59:21] gaining some traction here because it's
[59:23] developed over the course of the 1950s
[59:24] as well. It it gets published officially
[59:26] in 1960 in this paper by John McCarthy
[59:28] who obviously was one of the uh I I
[59:30] believe he's sort of the person who
[59:32] designed lisp and actually a different
[59:34] person at MIT actually implemented it
[59:36] but that has nothing to do with any of
[59:37] this. Point being, he's obviously the
[59:39] father of Lisp because he's the one who
[59:40] had the idea and he's the one that
[59:42] designed it and he's starting to talk
[59:44] about lisp and saying this is a way that
[59:46] we could do symbolic computation. Now
[59:49] remember lisp doesn't really have any
[59:51] concept of records at this point or
[59:53] anything like that. It's just sequential
[59:55] bags of stuff. So it's like okay we're
[59:57] going to have like a a list of symbols
[59:59] and to the extent that you're ever going
[1:00:01] to do processing on something that's
[1:00:02] like a record it's just up to you to
[1:00:03] kind of remember that the symbols will
[1:00:05] go in a particular order and that's how
[1:00:07] you're doing your processing. So they
[1:00:08] haven't really gotten this idea yet of
[1:00:10] structured data like this is what the
[1:00:12] computer's going to process. They're
[1:00:13] thinking in terms of processing lists,
[1:00:16] right? Because again there's they're
[1:00:18] like no high level languages. We got
[1:00:19] like forran coming in this time. We got
[1:00:21] list coming this time and then these
[1:00:23] experimental languages stuff like that.
[1:00:24] We don't have all these languages that
[1:00:26] we know about today.
[1:00:28] So
[1:00:30] Douglas T. Ross he's also working on
[1:00:33] stuff like this. They have a programming
[1:00:35] language that they're working on for
[1:00:37] this you know computerated modeling
[1:00:39] stuff that they're doing. and he's
[1:00:41] actually thinking what if we did
[1:00:44] structured data like what if we were
[1:00:45] computing on things that actually had a
[1:00:48] fixed size and this is all throughout
[1:00:49] the 1950s they're developing this and in
[1:00:52] 1960 contemporaneous with that list
[1:00:55] paper he publishes a paper and in this
[1:00:58] paper he keeps it classy right out of
[1:01:01] the gate he basically throws shade at
[1:01:03] lisp he's like look lisp is kind of dumb
[1:01:07] why would we compute
[1:01:10] only on things that basically have a
[1:01:13] next and previous pointer or like a tree
[1:01:14] where it just has a left and a right.
[1:01:17] What would give you the idea that the
[1:01:19] things you want to compute on only
[1:01:21] consist of two things? What you're doing
[1:01:23] is you're just using that and then
[1:01:25] you're constantly building up these like
[1:01:27] structures of like two pointer things to
[1:01:30] represent bigger things. Why don't we
[1:01:32] just store the bigger things directly?
[1:01:34] And he knows why. He gets it. He says,
[1:01:37] "Look, not only does it take more space,
[1:01:39] but it also takes more processing power
[1:01:42] because we've got to reconstruct the
[1:01:44] data we actually want by plowing through
[1:01:45] these lists all the time. And
[1:01:47] furthermore, we have to store them by
[1:01:49] keeping all of that interstitial stuff
[1:01:50] in there. And that's no good either,
[1:01:52] right?" So, he is 100% on point. And
[1:01:54] this is published in 1960.
[1:01:56] Contemporaneous with the list
[1:01:57] publication, contemporaneous with
[1:02:00] something like Alol 60. So, way way
[1:02:04] ahead of the curve here, right? because
[1:02:06] that means they had it running
[1:02:07] throughout the 1950s.
[1:02:10] Now, he calls this a plex. Doesn't call
[1:02:12] it a structure. He calls it a plex
[1:02:15] because I'm guessing he's bad at
[1:02:18] self-promotion. He never gets this term
[1:02:20] to stick anywhere. So, you know, we
[1:02:23] don't type plex in front of our thing.
[1:02:25] But to be completely honest, as far as I
[1:02:27] can tell from history, we should it
[1:02:31] should be called a plex. We should pound
[1:02:33] to find Plex to be struck because that's
[1:02:36] where the credit actually goes to. It's
[1:02:38] this guy right here and the other people
[1:02:40] that were on that team. So what does it
[1:02:43] look like? This is one of the great
[1:02:45] things about this era. Everyone
[1:02:46] publishes everything. It's really nice
[1:02:49] and it has to be condensed down into a
[1:02:51] paper because there's no YouTube. So I
[1:02:52] don't have to watch hours and hours and
[1:02:54] hours of things to find out what the
[1:02:55] heck is going on.
[1:02:57] This is an example of a complicated
[1:02:59] plex. This is in the original paper in
[1:03:03] 1960. And what does it have in it? Well,
[1:03:07] it has some data, an x and y coordinate
[1:03:10] for example, right? Just things that you
[1:03:12] might store like you would normally data
[1:03:14] members. It also has pointers already,
[1:03:18] right? These are basically things that
[1:03:19] are linking it to other things. So,
[1:03:21] we've got data members, we've got
[1:03:23] linkage members, and hold on to your
[1:03:26] butts because what is this stuff down
[1:03:28] here, right? Like, what is that? And I'm
[1:03:32] loving this, by the way, when I find
[1:03:34] this stuff in papers, right? Because I
[1:03:37] don't like to just read the abstract. I
[1:03:39] want to read the whole paper. Like, I
[1:03:41] paid my money and I want to see the
[1:03:42] whole movie to the end. Even with the
[1:03:45] end credits, even if the movie sucks, I
[1:03:47] kind of want to know. I'm just curious
[1:03:49] right now. So, I'm looking at this, I'm
[1:03:51] like, "What the heck is that? TRA 562
[1:03:55] like secret code stuff going on."
[1:03:58] So, what these actually are, and this is
[1:04:01] awesome,
[1:04:02] is check and fast are basically flags.
[1:04:06] And what Ross says is look, when we're
[1:04:08] processing this stuff, think of it this
[1:04:11] way. We could run one subruine and just
[1:04:14] based on what we stick in the plex, we
[1:04:17] could change how we're processing it. So
[1:04:19] if we do want this thing to go through a
[1:04:21] particular path, we set it. And if we
[1:04:24] don't want it to go through a particular
[1:04:25] path, we don't set it. Right?
[1:04:30] Just pausing for effect on that one.
[1:04:32] What's
[1:04:34] 562? What's 467?
[1:04:38] Those are addresses. That's an
[1:04:40] instruction. It's saying what we're
[1:04:41] going to do there is jump to a subruine.
[1:04:44] Those are function pointers. So we
[1:04:47] basically say sometimes we don't really
[1:04:49] want parameterization of what's going to
[1:04:51] happen. We just want a completely
[1:04:53] different thing to happen.
[1:04:55] And there is where you basically have
[1:04:57] your virtual function staring you right
[1:05:00] in the face right there in 1960
[1:05:03] contemporaneous with lisp.
[1:05:09] So, I'll just say
[1:05:14] our team,
[1:05:16] yeah, I was clapping for him, too. I was
[1:05:20] clapping for him, too. Ryan, team Fat
[1:05:23] Struck, we started in 1960 right here.
[1:05:26] We're We're like We're like the old sort
[1:05:28] of uh thing at a university, like the
[1:05:30] you know, the old sort of uh the club,
[1:05:32] right, that's been going forever. We We
[1:05:35] got roots, man. We got roots. We got
[1:05:37] hardcore stuff on our side.
[1:05:40] All right. So, he throws up an example.
[1:05:43] He's like, "Hey, let's suppose we want
[1:05:44] to model a line because remember he's
[1:05:46] working on CAD. He wants you to be able
[1:05:48] to type in this is the shape of the
[1:05:50] airplane engine and out comes the
[1:05:52] engine." So, we're trying to think about
[1:05:53] things. How do we model lines? How do we
[1:05:54] model surfaces? That sort of thing. He's
[1:05:56] like, "Well, one thing we could do is we
[1:05:59] could take the data for the line and we
[1:06:01] could put it in there. So those are like
[1:06:02] names of things and x and y coordinates
[1:06:05] things for like points and then we could
[1:06:07] have like connect it up with pointers.
[1:06:09] So a line would have a pointer to two
[1:06:11] different points and the points would
[1:06:12] point back to the line and we'd make
[1:06:14] basically a winged edge data structure
[1:06:16] right
[1:06:19] off the charts with what they were
[1:06:20] doing. It's kind of crazy but doesn't
[1:06:23] stop there. So that is at the servo
[1:06:25] mechanisms lab which later gets renamed
[1:06:27] to like electrical systems or something.
[1:06:29] It's a lab that's still around today, I
[1:06:30] believe, but it has a slightly different
[1:06:32] name. I think it might have said it was
[1:06:34] even one of the longest running labs.
[1:06:35] Anyway, so hardcore, but there's another
[1:06:38] MIT uh sort it's sort of like it's not
[1:06:40] on the main campus in Cambridge. It's
[1:06:42] off in Lexington. It's called the
[1:06:43] Lincoln Laboratory. Also very prominent.
[1:06:46] And this is the other side of a story.
[1:06:48] Remember I said we have this thing where
[1:06:50] C Horus is saying, I got these ideas
[1:06:52] from Ross. He was pretty cool. And then
[1:06:54] we also have that Allen uh that Alan K
[1:06:57] part where he's talking about hey
[1:06:58] sketchpad. So we haven't talked about
[1:07:00] the sketch part. We found out about Ross
[1:07:02] and he was hardcore. What about
[1:07:03] Sketchpad? How hardcore is that? Well,
[1:07:06] this is Ivan Sutherland. He's the guy
[1:07:08] who made Sketchpad largely by himself.
[1:07:11] Like he pretty much wrote it again lone
[1:07:13] wolf style. and he comes to the Lincoln
[1:07:16] laboratory in the summer of 1960 uh as
[1:07:19] an intern originally but he ends up
[1:07:21] doing his PhD uh at MIT here. So this is
[1:07:26] what he's doing. And in the course of
[1:07:29] there's these computers called the TX
[1:07:30] series. There's like TX0 and TX2 and
[1:07:33] they're basically made by this guy named
[1:07:36] uh Wes Clark is at MIT and they're like
[1:07:38] they're making the computers, right? I
[1:07:40] mean that's the way this stuff worked
[1:07:42] back then is like the university
[1:07:43] actually had to make computers that they
[1:07:45] would use because nobody knows like what
[1:07:47] a computer even is yet and they're like
[1:07:49] building different versions of them and
[1:07:50] figuring out what the heck's going on.
[1:07:52] And this TX series of computers, they
[1:07:54] were pretty unusual because they
[1:07:56] actually had a display.
[1:07:58] Like we're back in the 1950s, right? So
[1:08:02] the idea that a computer was going to
[1:08:03] draw a picture for you that wasn't on a
[1:08:06] plotter that would like draw on a piece
[1:08:08] of paper is like completely unheard of.
[1:08:10] Like no one's doing anything like that.
[1:08:12] It's very rare. And so there's only a
[1:08:14] few places in the world that even have a
[1:08:16] computer that can display something. But
[1:08:18] the TX series of computers can. And this
[1:08:21] this guy who was architecting them, that
[1:08:22] Wes Clark guy, uh he was very forward
[1:08:25] thinking as well. And he was basically
[1:08:26] saying, "I think there's something here.
[1:08:28] I'm going to make it so it can integrate
[1:08:30] with a light pen that can like see
[1:08:32] what's on the CRT, and I'm going to like
[1:08:34] have the CRT be able to display stuff
[1:08:35] that the computer has." So, he makes
[1:08:37] this new computer called the TX2, which
[1:08:38] is an iteration of TX0. There's no TX1,
[1:08:41] I'm told. I don't know the story behind
[1:08:42] that, but he makes thing called the TX2.
[1:08:45] And obviously when you make something
[1:08:46] like this, it's hard to get time on it
[1:08:48] because it's just there's this one that
[1:08:49] was built. But he makes this and it's
[1:08:52] under a thing for the Air Force, the US
[1:08:54] Air Force, where they don't really care
[1:08:57] what you do with this computer. They
[1:08:59] were funding it not because they wanted
[1:09:01] MIT to compute something for them, but
[1:09:04] because they wanted MIT to figure out
[1:09:07] what happened with large trans like
[1:09:10] large arrays of transistors for
[1:09:11] computing like like if we make big
[1:09:12] computers, what happens? So this is very
[1:09:15] helpful because it means that the
[1:09:18] computing time on the computer isn't
[1:09:21] necessarily being taken up by some
[1:09:23] specific grant thing that they have to
[1:09:25] do. It's more flexible.
[1:09:28] So Ivan Sutherland manages to convince
[1:09:31] Wes Clark that he's got this idea for
[1:09:34] being able to draw on the surface of the
[1:09:36] thing, make like a drawing program.
[1:09:39] Could he have a slot on the TX2? And
[1:09:43] thank God West Clark said yes
[1:09:46] because from then on Southerntherland
[1:09:49] went in at 4 in the morning because that
[1:09:52] was the slot that was open to work on
[1:09:54] this thing. That's the TX2. And that
[1:09:57] right there is the uh is actually
[1:10:00] Sketchpad running. And so he would work
[1:10:02] on this. And I mean when I say work on
[1:10:05] this, you'll notice it's not like a
[1:10:06] keyboard here. You're not like typing in
[1:10:08] code into an editor. It was still like
[1:10:10] had to be manually entered in various
[1:10:12] ways, right? There was actually like a
[1:10:13] secretary who would enter some of it. He
[1:10:15] entered some of it, right? It's like so
[1:10:17] it's very laborious to develop things in
[1:10:18] the 1950s. Again, just to kind of hammer
[1:10:20] that home, these guys did not have much
[1:10:22] to work with, but he's working on this
[1:10:24] sketchpad program. And what you could do
[1:10:26] with it is stuff that we completely take
[1:10:28] for granted today as stuff you could
[1:10:30] just do. You could do things like draw
[1:10:32] lines with the light pen just like we
[1:10:34] would with a mouse. And it's actually
[1:10:36] fairly intelligent. It knows things like
[1:10:38] snapping. Like if you go and you're
[1:10:40] going to connect back to a point, it
[1:10:42] knows that it's it's not stupid, right?
[1:10:44] So it's not just doing random line
[1:10:45] drawing. It's thinking about those lines
[1:10:46] as well. We'll talk a little bit more
[1:10:48] about that because there's a lot more to
[1:10:49] cover there. But Alan K, who I said was
[1:10:52] the person who got us into this in the
[1:10:54] first place. The reason we're looking
[1:10:54] into it, he calls Sketchpad, the
[1:10:57] eventual thesis that Ivan Sutherland
[1:10:59] would publish on it, he calls it the
[1:11:00] most significant single thesis ever
[1:11:04] done. He says that it was like so
[1:11:06] impactful and so important not just to
[1:11:08] him but to everybody and honestly he's
[1:11:12] probably right. Out of sketchpad comes a
[1:11:15] lot of research in computer graphics. It
[1:11:16] comes the whole object-oriented concept
[1:11:18] from Alen K. Uh the the whole idea of
[1:11:21] interacting with computer in this way is
[1:11:23] very very new. CAD and the idea of a CAD
[1:11:26] program kind of comes out of this as
[1:11:28] well.
[1:11:29] Now it's so early in computing. I just
[1:11:33] want to hammer home one more time the
[1:11:35] kinds of things that Sutherland talks
[1:11:37] about if you read about his experience
[1:11:38] with Sketchvad developing at the time
[1:11:40] when he published the thesis.
[1:11:42] No one's ever even thought about like if
[1:11:46] I want to draw a line and then change
[1:11:48] where it is, I don't have to erase the
[1:11:50] line anymore. I could just move where it
[1:11:53] is. This is a completely new concept
[1:11:56] that no one's ever thought about before
[1:11:58] because for the rest of history, if you
[1:12:00] drew a line, you had to at least remove
[1:12:02] that line before you drew it again.
[1:12:04] Right? So, they're literally figuring
[1:12:07] out here in real time the kinds of
[1:12:10] paradigms that we just take completely
[1:12:12] for granted when you sit down to use a
[1:12:13] computer. The fact that you can move
[1:12:14] things around by pointing at them,
[1:12:16] completely new. That's what we're
[1:12:18] talking about here.
[1:12:20] Another example of that is rubber
[1:12:22] banding.
[1:12:24] They were thinking, "Oh, when you draw a
[1:12:25] line, you must have to move the light
[1:12:26] pen along the line to draw the line,
[1:12:28] just like you would with a T-square or
[1:12:30] something like that, right?" And they
[1:12:32] were like, "Wait a minute. We could just
[1:12:34] have the light pen attach the end of the
[1:12:37] line and move it around until you got it
[1:12:39] where you want it and then you could let
[1:12:40] go and that would be where it was." So
[1:12:42] even basic stuff like this was news to
[1:12:44] them. They were discovering it, right?
[1:12:47] So it's really, really early. That's how
[1:12:48] early we're talking about.
[1:12:51] Now, as fate would have it, when he's
[1:12:53] working on this program, who walks in,
[1:12:55] but Mr. Douglas Ross, they were at
[1:12:58] separate laboratories, but they did talk
[1:13:00] to each other a lot. And the reason for
[1:13:02] that was because Ross' group is working
[1:13:05] on CAD. They're not displaying much
[1:13:08] about it, right? They're not working
[1:13:10] interactively, but they're trying to do
[1:13:12] these like machined creations that are
[1:13:14] based on human input.
[1:13:17] So because Sutherland's pretty new to
[1:13:19] this stuff, he talks to Ross and he's
[1:13:22] like, "How do I make stuff like lines?
[1:13:24] Like, how do I do that kind of data
[1:13:25] modeling in the computer? Do you guys
[1:13:27] have ideas?" And Douglas Ross is like,
[1:13:29] "Have I got an idea for you? It's called
[1:13:31] a Plex, right?" And as we saw, Plex is
[1:13:35] pretty awesome. And Ivan Sutherland is
[1:13:37] probably one of the smartest people on
[1:13:38] planet Earth. So he recognizes right
[1:13:40] away this is a good idea, too. So he's
[1:13:43] like, "All right, we're doing it."
[1:13:44] Right? He says, "What I'm going to be
[1:13:47] making this program to do is have a
[1:13:49] bunch of like primitives, right? Like
[1:13:50] I've got lines and things like that that
[1:13:52] I'm going to create. And I don't have
[1:13:54] that many types of things. Like I'm just
[1:13:56] going to have like lines and you know
[1:13:57] later uh actually it was Claude Shannon,
[1:13:59] the father of information uh theory,
[1:14:01] right? Who says you should put circles
[1:14:04] in it too?" So there's all these kind of
[1:14:05] like little answers. If you actually go
[1:14:07] read this yourself, you'll find there's
[1:14:08] so many things I couldn't fit in this
[1:14:09] lecture because it would have been like
[1:14:10] eight hours, right? But anyway, so he's
[1:14:12] saying we're going to have all these
[1:14:13] instances of things, lots of lines and
[1:14:15] stuff like that. So I don't really need
[1:14:17] anything more than just this n component
[1:14:19] thing and I'll just have lots of those
[1:14:21] and that's how we'll do it. This is how
[1:14:22] I'm going to write the program. And here
[1:14:25] is his diagram from his thesis about how
[1:14:27] he's going to structure, right? How or
[1:14:29] how he did structure lines and points,
[1:14:32] right? And there's some information
[1:14:33] missing from this because, you know, I
[1:14:34] mean, if you're sketching things in
[1:14:35] Sketchpad with that light pen and it's
[1:14:37] very slow, right? It's not he can't make
[1:14:39] slides with software like we have today.
[1:14:40] Not that the software I used to make the
[1:14:42] slides was particularly better than
[1:14:43] Sketchpad, but you get the idea. Um, so
[1:14:46] it's not completely documented in here,
[1:14:47] but you know, you can see here it's got
[1:14:49] the line, it's got a pointer to each of
[1:14:50] the points and so on and the coordinates
[1:14:52] sort of sketching that out. And hey,
[1:14:54] it's exactly like that paper from Doug
[1:14:56] Ross, right? And Doug Ross published
[1:14:59] this in 1960s. So Ross and his team were
[1:15:02] already thinking along these lines
[1:15:03] before Southerntherland even got to the
[1:15:05] lab, right? And started working on
[1:15:07] Sketchpad in the later a little bit
[1:15:09] later in the early 60s. So that's how
[1:15:11] this this whole thing ties together.
[1:15:13] Ross and Sutherland are like having a
[1:15:15] huge party here and it's awesome.
[1:15:18] And if you remember, we had these things
[1:15:20] in the Plex that were basically like
[1:15:22] jumps, right? They were like sub
[1:15:23] routines. They were the virtual
[1:15:24] functions at the time or we maybe would
[1:15:26] call them uh not so virtual functions,
[1:15:28] although you could implement that way.
[1:15:29] We just called them function pointers,
[1:15:30] right? And you can do all the same
[1:15:31] things you can do with a function
[1:15:32] pointer. That was something that Doug
[1:15:34] Ross was talking about in his plexus in
[1:15:35] the original paper and it's right there
[1:15:39] in Sketchpad as well. This is how he did
[1:15:42] things like I want to go ahead and draw
[1:15:44] this shape but I don't want to bother
[1:15:46] having actual different data types uh be
[1:15:49] completely specialized having having the
[1:15:50] routines completely specialized. So what
[1:15:51] I'll do is I'll just have like a few
[1:15:54] entries in the data type that say how
[1:15:55] will I display it what's what would I
[1:15:57] jump to to display it to figure out how
[1:15:59] big it was or to move it. So again,
[1:16:02] virtual functions right there. They come
[1:16:04] from the plexes. He puts it in and that
[1:16:06] is how he actually implemented that kind
[1:16:08] of like parametric behavior in this
[1:16:11] program in in Sketchpad.
[1:16:14] Now,
[1:16:16] because we've already got one applause
[1:16:19] line before for this kind of thing, I'll
[1:16:22] just point out there's empty space in
[1:16:25] between these things here. And on the
[1:16:27] previous one, I was like, well, the
[1:16:29] reason that there's empty space on those
[1:16:30] is because, you know, I probably didn't
[1:16:31] have time to to draw it out. And that
[1:16:33] was true for that diagram because I know
[1:16:34] more about the data structure because
[1:16:35] I've spent way too much time looking at
[1:16:37] this program. But in this one, those are
[1:16:41] actually space in the strct. Those
[1:16:45] fields there, there's there's gaps,
[1:16:47] right? So, why are there gaps? Why are
[1:16:50] there gaps in this thing? And I wanted
[1:16:52] to know. So, I'm coming through this
[1:16:53] like what are the gaps about, right? Is
[1:16:55] it just the same as the other one where
[1:16:56] it was like you just didn't draw it in
[1:16:58] there or something? What are the gaps
[1:17:00] about? I found it. At present, all
[1:17:02] generic blocks still carry space for all
[1:17:04] the information in any of them simply
[1:17:06] because of historical reasons. This
[1:17:08] accounts for the spaces seen in figure
[1:17:11] 37. What this means is
[1:17:14] Sketchpad is on Steam Team Fat Struct
[1:17:17] right in 1963. He was still doing the
[1:17:21] same thing that the Plex was doing. He
[1:17:22] was just saying, "Look, I don't really
[1:17:24] maybe I should have gone back and tried
[1:17:26] to figure out some way to compact these,
[1:17:27] but you know what? Uh, we didn't end up
[1:17:29] doing that." And so, he kind of just has
[1:17:30] that mentioned there. It's like, "Yep,
[1:17:32] all of them are the same size and we
[1:17:33] just leave those fields out if they
[1:17:35] weren't going to be there, right?" So,
[1:17:38] bending it a little bit there because it
[1:17:40] in the sketch paper, it's very hard to
[1:17:42] tell exactly the way because he doesn't
[1:17:44] give explicit data layouts for a lot of
[1:17:45] things. It's hard to tell whether or not
[1:17:48] he was using like things that always had
[1:17:51] fat strct or whether it was more like
[1:17:53] semi-istributed unions. So there were
[1:17:54] pairs of things that would have been
[1:17:56] used differently. So it's either team
[1:17:58] fatstruct or team overlay fatstruct but
[1:18:01] it's one or the other.
[1:18:04] All right. So we've come to the part
[1:18:05] where we can build our tree. As far as I
[1:18:07] can tell doesn't go any deeper than
[1:18:08] this. This is where it actually started
[1:18:10] for reals this time. Doug Ross and his
[1:18:13] team this idea of plexes. It goes to
[1:18:16] Ivan Sutherland because he works there
[1:18:17] and he asks us for their advice on how
[1:18:19] to build the stuff in Sketchpad and he
[1:18:21] picks up the Plex concept. It also goes
[1:18:24] to CH horror. That Plex uh concept goes
[1:18:27] to him because they sit on the algo
[1:18:29] committee together. So that's our first
[1:18:31] branch. We then have that horror paper
[1:18:34] was read by Dah and Nygard who decide to
[1:18:37] use it to create their simulass idea
[1:18:40] and both of those you know Simula and
[1:18:43] Sketchpad influence Alan K to create the
[1:18:46] small talk branch of oop. Meanwhile the
[1:18:50] experience with simula influences
[1:18:52] bejornstrip to create with classes and
[1:18:55] then C++.
[1:18:58] Now by the way this is an inheritance
[1:18:59] hierarchy that matches the domain model.
[1:19:06] But there's a fun part of it.
[1:19:09] Some of you may know this, some of you
[1:19:10] may not because I mean, why would you?
[1:19:12] Obviously, we know C++ has multiple
[1:19:14] inheritance. It got multiple
[1:19:15] inheritance. Not right away, but it got
[1:19:16] it eventually. Small talk never did
[1:19:19] single inheritance.
[1:19:21] However, single inheritance will get you
[1:19:24] C++,
[1:19:26] but it won't get you small talk. You
[1:19:28] need two parents,
[1:19:31] right?
[1:19:32] [Applause]
[1:19:35] What can I say? So, that's the actual
[1:19:38] end. Now, we've built our tree. We're
[1:19:40] finally done. We know where this stuff
[1:19:42] came from,
[1:19:45] right? It was long.
[1:19:47] Of course, there is a personal angle to
[1:19:50] this as well. So, I should probably say
[1:19:53] that the reason I decided to go do all
[1:19:56] this, it probably wouldn't be, you know,
[1:19:58] I'm on that thing called the internet
[1:20:00] all the time. And most of the time, I'm
[1:20:03] just going to post something snide as a
[1:20:05] reply and not think about it again. So,
[1:20:08] why did I actually go and do all this
[1:20:10] research just for this? Why didn't I
[1:20:13] just say, "Who cares about these things?
[1:20:15] I don't use those compile time
[1:20:16] hierarchies." And and just, you know,
[1:20:19] post something mean on Twitter. Why
[1:20:20] didn't I do that this time? It would
[1:20:22] have saved me a lot of time. Of course,
[1:20:24] I wouldn't have had anything to present
[1:20:25] today, but it would have saved me a lot
[1:20:27] of time. Well, here's why. Back in 1997,
[1:20:32] which by the way is right around the
[1:20:34] same time that we started this talk,
[1:20:35] right? The looking glass uh stuff that
[1:20:38] they did with entity component systems
[1:20:39] was 1998, which means they would have
[1:20:42] been working on it in 1997. It would
[1:20:44] have been up and running at that time.
[1:20:45] So, it's right at the same time. I'm
[1:20:48] working with a fellow called Chris
[1:20:49] Hecker and I'm brand new. Like I am I am
[1:20:52] literally out of high school so I don't
[1:20:54] know anything. Like I I programmed a ton
[1:20:56] as a kid but you know if you ask me you
[1:20:58] know uh my thoughts on computer
[1:21:00] architecture or something like that I
[1:21:02] obviously would have answered very
[1:21:03] confidently and been completely wrong
[1:21:05] about everything. So he says we're going
[1:21:08] to need a level editor. This is
[1:21:10] basically a game that we're working on.
[1:21:11] We need a level editor that does CSG on
[1:21:14] spheres. So the idea was you take these
[1:21:16] spheres and you build a level up out of
[1:21:18] like unioning them together, right? Like
[1:21:19] a standard CSG modeling kind of stuff.
[1:21:22] But of course I don't really know any
[1:21:24] CSG stuff. I have like really know how
[1:21:26] to do that. So I go using I think it was
[1:21:28] sightseer at the time like nowadays you
[1:21:30] might use like Google Scholar or
[1:21:31] something to search for papers. So I go
[1:21:34] to use like sightseer I think was up at
[1:21:35] the time or maybe there was a precursor
[1:21:36] to it and I can't remember the actual
[1:21:38] one but there were things at the time
[1:21:40] even then this early because the
[1:21:42] internet's you know not the internet's
[1:21:44] only been available to the public for a
[1:21:45] short time really like was arponet you
[1:21:47] know until the the mid9s right so when
[1:21:51] when we're looking at this I go to crawl
[1:21:54] papers and I'm like okay CSG on spheres
[1:21:56] like to try to type some things in read
[1:21:57] some papers you what am I going to do
[1:22:00] and I come across this thing called
[1:22:01] alphashapes and alpha Alpha shapes are
[1:22:03] just the name that someone in a paper
[1:22:05] had given us something that was
[1:22:06] basically implicit services. I don't
[1:22:07] really know why they called alpha shapes
[1:22:08] because it escapes me now. I'm sure I
[1:22:10] knew at the time because I just read the
[1:22:11] paper, but for some reason they're
[1:22:12] talking about these alpha shapes. I
[1:22:13] looked at I was like, oh, if it's like
[1:22:15] spheres, but when you move them
[1:22:16] together, they make this like nice
[1:22:18] smooth join. They don't make that hard
[1:22:20] edge. I was thinking, oh, for levels
[1:22:22] that would be like really cool. That
[1:22:23] might be like way better than if we did
[1:22:25] CSG on spheres because it would have
[1:22:26] this like really cool effect. So it was
[1:22:29] kind of be like on the inside of these
[1:22:31] things which are you know typically
[1:22:32] called metabols and it was going to be
[1:22:35] like sort of the negative space of the
[1:22:37] metabols. So I made a modeler for this
[1:22:40] and I called it mega man which has
[1:22:42] nothing to do with mega man completely
[1:22:44] legally legally distinct from that. It's
[1:22:46] kind of change one letter and maybe it's
[1:22:48] the same but nothing to do with this.
[1:22:49] It's just negative space metabols. And
[1:22:52] this is what it looked like. And
[1:22:54] effectively what you did is you, you
[1:22:56] know, picked things in it. You can see
[1:22:58] those spheres there are metabols.
[1:22:59] They're the kind of spheres you put
[1:23:00] together. And they form these kind of
[1:23:02] surfaces. And we're seeing the inside of
[1:23:04] what you're creating, right? Because
[1:23:05] it's a negative space. So that's why it
[1:23:06] looks kind of weird. You would normally
[1:23:08] see the outside in a metabol modeler.
[1:23:10] But this is what I was working on. Well,
[1:23:12] I I mean, and it's finished. Like you
[1:23:14] can use it. I still have to this day.
[1:23:15] You can model stuff around. It's it's
[1:23:17] pretty janky, but it it does what it's
[1:23:18] supposed to do, right? And so the way
[1:23:21] that you interacted with it is you like
[1:23:22] picked those spheres and you could move
[1:23:25] them around by dragging the mouse and
[1:23:26] that sort of stuff. The same sort of
[1:23:27] things, right, that like Sketchpad was
[1:23:29] doing only, you know, with much better
[1:23:31] hardware and and much more advantages in
[1:23:33] ter of development. Same kind of idea
[1:23:34] because, you know, like Southerntherland
[1:23:36] was so far ahead, right? And so if you
[1:23:39] wanted to create stuff, you might select
[1:23:41] things like here. I don't know if you
[1:23:42] can see it. selected those two metabols
[1:23:44] at the top and then I've just like inst
[1:23:46] there's a thing you could like rapidly
[1:23:47] stamp them down. I kind of just drag
[1:23:48] them and like stamp stamp stamp stamp
[1:23:50] and you can create more of the level
[1:23:51] just kind of like blobbing things
[1:23:52] together.
[1:23:54] So it was a selection based UI like most
[1:23:56] programs are where I select a bunch of
[1:23:58] things and then I wanted the program to
[1:23:59] basically have a nice architecture for
[1:24:01] being able to do that and then present
[1:24:03] the user with the user interface that
[1:24:05] would be appropriate for that selection.
[1:24:08] And this is actually a really hard
[1:24:10] architecture problem if you're not
[1:24:13] experienced which I wasn't because it's
[1:24:15] like well if what you've been told is
[1:24:17] that you make these hierarchies like
[1:24:19] these class hierarchies and things like
[1:24:20] that and what we're really saying is I'm
[1:24:22] going to select all these things that
[1:24:23] are really derived types of things but
[1:24:26] now I want this higher level thinking
[1:24:28] thing to look across everything that
[1:24:30] you've selected and come up with a plan
[1:24:33] for what the unified interaction would
[1:24:35] be across those things. And then when
[1:24:37] you actually want to do the interaction,
[1:24:39] it's got to make sense for what's going
[1:24:40] on. And this is really tricky because
[1:24:42] the inheritance thing doesn't help you
[1:24:43] at all for this. It fights you. You're
[1:24:45] constantly like, "Oh, do I just add a
[1:24:46] bunch of like functions to the base
[1:24:48] class that's anything you might want to
[1:24:50] do to a class? Do you basically fatty
[1:24:52] structure interface, right, but leave
[1:24:54] the hierarchy in place? There's all
[1:24:55] these things you might think to do and
[1:24:57] they just don't work very well." But I
[1:24:59] was, you know, pretty gung-ho at the
[1:25:00] time. Uh, you know, I'm not old like I
[1:25:02] am now. So, at the time, I don't mind
[1:25:03] typing a lot. So, I go to town on this.
[1:25:06] And I'm like, "All right, I'm going to
[1:25:07] try to figure out how to do this
[1:25:09] cleanly,
[1:25:11] quote unquote."
[1:25:12] And we end up with crap like this. Now,
[1:25:15] a lot of times I try to convince people.
[1:25:17] I'm like, "Look,
[1:25:18] everyone thinks that I was like some C
[1:25:21] only programmer. I just don't know
[1:25:23] anything about like huge crazy hairy
[1:25:25] object-oriented programming or anything
[1:25:27] like that. It's just like you don't
[1:25:28] understand." It's like, "No, dude. I
[1:25:31] wrote some of the most ridiculous oop
[1:25:34] stuff you have ever seen when I was like
[1:25:36] 20. I was doing crap like this all the
[1:25:39] time. It was awful. I'm not proud of it.
[1:25:42] But here is what's going on. Right. So,
[1:25:44] the way I chose to solve this problem,
[1:25:47] never mind the fact that like I'm doing
[1:25:49] the implementation inheritance thing up
[1:25:50] there with with a template on the class.
[1:25:53] This if you've ever seen this trick,
[1:25:54] it's an old school. So, it's like
[1:25:56] there's so much stuff in this codebase.
[1:25:57] You would it's a nightmare. But anyway,
[1:26:00] so if you look at what's going on here,
[1:26:01] I have get and set functions like you're
[1:26:02] supposed to have on any proper object
[1:26:06] and you can get the center, you can set
[1:26:08] the center, that sort of thing. Get the
[1:26:09] service radius, set the service radius,
[1:26:10] right? And now what I want to do is I
[1:26:13] want to have some way that these can be
[1:26:14] interacted with in a unified way. So
[1:26:17] what do I do? Anytime you create one of
[1:26:19] these things, I build a parallel
[1:26:22] structure. I create a property list that
[1:26:25] basically is callbacks using this is
[1:26:28] called a rich hickey functor. I'm not
[1:26:31] kidding. It was a callback that you
[1:26:34] could use to do type safe callbacks back
[1:26:36] in the early days of C++.
[1:26:39] I'm trying to tell where is the camera?
[1:26:41] Seriously, like I have done ridiculous
[1:26:44] oop stuff. You if you don't believe me
[1:26:46] after seeing this, I do not know what to
[1:26:48] tell you. We can post more of this code
[1:26:50] if we need to.
[1:26:52] So anyway, so basically when it's
[1:26:54] created, it creates a parallel hierarchy
[1:26:55] that's just it's not actually the
[1:26:57] properties. It's just callbacks that
[1:26:59] would get and set the properties, right?
[1:27:02] And then you know this this is what that
[1:27:04] class looked like, right? Here's the get
[1:27:06] and set callbacks abstracted into a
[1:27:08] property. And then if you wanted to use
[1:27:09] it, you could loop over the properties.
[1:27:12] you could create a modification
[1:27:15] that was typed on the property, right,
[1:27:19] to do the changes you actually wanted to
[1:27:21] do.
[1:27:23] Okay? And that's to support like
[1:27:25] dragging and undo and things like that.
[1:27:28] So this is what it looked like if you
[1:27:30] drew it out. I have a metabol
[1:27:32] and center. The data is in the metabol,
[1:27:35] right? Just like a good object-oriented
[1:27:37] programming uh thing would tell you to
[1:27:39] do. It's encapsulated inside the
[1:27:40] metabol. I create parallel I call them
[1:27:44] property universes. I create property
[1:27:46] universes. All of the center properties,
[1:27:49] all of the radius properties and they
[1:27:51] are callbacks
[1:27:54] to modify or retrieve the data in the
[1:27:57] actual entity here, right? The metabol.
[1:28:00] And then when you interact with it, you
[1:28:02] use modifications to interact. And this
[1:28:05] way when I wrote the code I could think
[1:28:08] about things in terms of the center or
[1:28:10] in terms of the radius. So what I do is
[1:28:12] when you multi-selected I'd go what are
[1:28:14] all the property types that you've had
[1:28:17] and I'll just make interactions that
[1:28:19] work with those property types and I'll
[1:28:20] put up little UI elements that work with
[1:28:22] those property types. If the diagram
[1:28:25] looks familiar to you it's because you
[1:28:26] have a good memory because this talk is
[1:28:28] very long.
[1:28:30] If I had a brain I would have realized
[1:28:32] you don't need that. just put the
[1:28:34] properties in the actual universes
[1:28:37] themselves and use an ID for lookup and
[1:28:39] it's an entity component system. It's
[1:28:42] the same architecture. It's just I
[1:28:44] sucked at it and looking glass was good.
[1:28:47] That's the difference, right?
[1:28:52] So anyway, this was the slide I showed
[1:28:55] at the beginning. This is the slide that
[1:28:57] I did. You see what I'm talking about,
[1:29:00] right?
[1:29:02] My bad, right? This was my bad. I
[1:29:05] screwed up. I say that I don't blame
[1:29:07] myself because I was a kid, but really,
[1:29:10] I mean, I should have thought it
[1:29:11] through. So, anyway,
[1:29:14] in 2024, when I was accidentally on the
[1:29:17] internet, like I should not have been,
[1:29:20] I'm thinking to myself,
[1:29:27] how the heck did Sketchpad do this
[1:29:28] anyway? because they must have had like
[1:29:31] the same problems that I had because he
[1:29:33] could do all this stuff. It wasn't just
[1:29:35] a shape drawing program. I withheld some
[1:29:38] information from you if you've never
[1:29:39] seen Sketchpad before. I apologize. It's
[1:29:41] for dramatic effect. It's worth it.
[1:29:43] Trust me. It could do a lot of other
[1:29:45] stuff than just draw. The just drawing
[1:29:48] stuff is the stuff that like Adobe
[1:29:50] copied or things like that because that
[1:29:52] was the part that they could understand.
[1:29:55] The hardcore stuff only Sutherland knows
[1:29:57] how to do. And here's what that looks
[1:29:59] like. You could say, "I want these lines
[1:30:01] to be like perpendicular to each other."
[1:30:03] And it would do it right. You could take
[1:30:06] a drawing like this and pick a point
[1:30:09] that's not even a point. It's the
[1:30:11] intersection of two lines and not just
[1:30:14] snap, but say I want this radius
[1:30:19] from now on to always have its center
[1:30:23] point, like the circle arc. It's going
[1:30:26] to be drawn around that intersection and
[1:30:28] not for snapping but for always. So that
[1:30:32] if I then go do some constraints on this
[1:30:34] thing which Sutherland's about to do.
[1:30:35] He's going to say make that
[1:30:36] perpendicular to that perpendicular to
[1:30:38] that perpendicular to that which you
[1:30:40] can't do in anything from Adobe right to
[1:30:43] go get AutoCAD or something for this.
[1:30:45] And by the way AutoCAD didn't add it
[1:30:47] till like 2007 or something like this.
[1:30:49] They didn't have it in AutoCAD Flint.
[1:30:51] Right?
[1:30:53] When you tell it those things, you say,
[1:30:55] "Okay, that's what I want my shape to
[1:30:56] be." It'll just solve it for you. And if
[1:30:58] you move it, move the points around,
[1:31:01] it'll solve it again into whatever the
[1:31:04] closest shape is, right? Using like a
[1:31:06] relaxation le squares kind of thing.
[1:31:09] And I'm like, "What the heck?" I
[1:31:12] remember this. It's, you know, because
[1:31:14] I'd seen this demo before. And I'm
[1:31:17] sitting there thinking, you know, that
[1:31:19] whole compile time hierarchy thing and
[1:31:21] Allan Case like he saw Sketchpad and I
[1:31:23] I'd known those parts, you know, all the
[1:31:25] details I had to learn for this talk,
[1:31:27] but like I'm like, what the heck did he
[1:31:29] do? He's working on this like crap
[1:31:32] computer. I get that he's way smarter
[1:31:34] than me, so fair enough. But he still
[1:31:37] had to do something, right? So what did
[1:31:39] he do? What does a really smart person
[1:31:41] do when they're faced with this
[1:31:43] situation? because he's creating stuff
[1:31:45] that people who came after him who have
[1:31:47] like crazy debuggers and wizzywig
[1:31:50] editing and the ability to run things
[1:31:51] quickly and iterate, he they don't have
[1:31:53] to go in at 4 in the morning and enter
[1:31:54] things manually into a computer.
[1:31:57] How did he do it? Because no one did it
[1:31:59] afterwards for decades.
[1:32:04] So let's take a look.
[1:32:06] If we go in and we look at how he
[1:32:08] represented constraints, he represented
[1:32:10] constraints by saying there's going to
[1:32:12] be variables that are constrained. So
[1:32:14] I'm going to have some variables things
[1:32:16] like uh this point or this line that
[1:32:19] sort of thing would be considered a
[1:32:20] variable in the system. Something that
[1:32:22] is like a very primitive element of the
[1:32:24] system. So it could do that. You'd pick
[1:32:27] those and then you would have a certain
[1:32:28] type of the constraint essentially which
[1:32:30] is like what you know what am I actually
[1:32:32] going to be doing with this particular
[1:32:33] constraint. But they're relatively
[1:32:34] generic in this way.
[1:32:36] And then the things you could constrain,
[1:32:38] scalers, points, this is text, digits,
[1:32:40] and dummies. These are the different
[1:32:41] things you could constrain. They're sort
[1:32:43] of all like again, you know, sort of uh
[1:32:45] almost team fat struck there, right?
[1:32:47] They're kind of like all things you can
[1:32:49] reference as a variable without needing
[1:32:50] to know which one you're looking at.
[1:32:54] And so you can remember when we were
[1:32:56] looking, we were talking about here's
[1:32:57] how those lines of the line would not
[1:33:00] necessarily be something that was
[1:33:02] constrained, right? because it's kind of
[1:33:04] a it's a bigger thing than these are. Uh
[1:33:06] but the points would potentially be
[1:33:08] something that was constrained, right?
[1:33:10] So you might say things about them in
[1:33:11] that way. And I don't know all the
[1:33:13] specifics of how the constraints worked
[1:33:15] because he doesn't publish like in the
[1:33:17] thesis it only talks about to a limited
[1:33:18] degree. So I can't give you a perfect
[1:33:20] breakdown of exactly every piece of the
[1:33:22] system, but I mind as much out of it as
[1:33:24] I could.
[1:33:26] And he goes on to talk about how this
[1:33:28] thing was architected so that he could
[1:33:29] solve things. He said the ring structure
[1:33:33] which we have not looked at yet was
[1:33:35] designed to permit rapid constraint
[1:33:37] satisfaction. So what is this ring
[1:33:40] structure? What does he mean by that?
[1:33:41] But he's pinning it on that. He's like
[1:33:43] saying the ring structure was really
[1:33:45] important and that's what's letting us
[1:33:46] do this stuff.
[1:33:48] He also says all references made to a
[1:33:51] particular end component element or
[1:33:52] block are collected together by a string
[1:33:53] of pointers which origin that block
[1:33:56] which is kind of a type of ring
[1:33:58] structure, right? And he says this,
[1:34:00] which really throws you for a loop when
[1:34:02] you're first reading the thesis. In the
[1:34:03] data storage structure, the separation
[1:34:05] of general specific is accomplished by
[1:34:07] collecting all things of one type
[1:34:08] together as chickens which belong to a
[1:34:11] generic hen.
[1:34:14] Now, I will save you the trouble, those
[1:34:16] of you who want to read this thesis
[1:34:19] about what those mean.
[1:34:22] A hen is a sentinel of a linked list. A
[1:34:26] chicken is a link in a linked list that
[1:34:30] points back to the sentinel ex
[1:34:32] essentially, right?
[1:34:35] So
[1:34:37] here is how the data is laid out. Type
[1:34:41] is a chicken. Link quote unquote.
[1:34:45] Specb is a hen. So now when we go back
[1:34:48] to this uh type that we've already
[1:34:50] looked at, we can see them up there at
[1:34:51] the top. Type is the chicken. Spec B is
[1:34:54] the hen. This is sort of the workhorse
[1:34:57] of the structural elements of this
[1:34:59] system. And the way that it works is
[1:35:02] that chicken at the top links it into a
[1:35:05] giant linked list with all of its
[1:35:07] siblings at its level of whatever it's
[1:35:09] doing. And the specb hen is the sentinel
[1:35:13] for the list of all the things that are
[1:35:14] like subordinate to this thing. So it's
[1:35:16] like an up and down kind of a thing
[1:35:17] that's going on there, right? So chicken
[1:35:20] and hen.
[1:35:23] Here is how he actually draws it. You
[1:35:25] can see it's just a like list exactly
[1:35:27] like we expect. Key or hen threw me for
[1:35:30] a long time until I got it. Key or hen
[1:35:33] just means hen. For some reason in the
[1:35:36] paper he has he never says what a key is
[1:35:38] until this one part where he's like
[1:35:40] sometimes I also call a hen a key.
[1:35:46] So anyway,
[1:35:48] okay. He then goes on to present this
[1:35:51] and this is the runtime structure of
[1:35:55] sketchpad. You start with a universe and
[1:35:58] it has a sentinel or hen, right? It has
[1:36:02] a sentinel that has a ring inside of
[1:36:04] which is variables, holders,
[1:36:06] constraints, and topos. Again, not a
[1:36:08] compile time hierarchy, actually a
[1:36:09] runtime set of rings, right? So this is
[1:36:12] not baked into the compilation of this
[1:36:14] program in any particular way. It's just
[1:36:15] how the rings are structured at runtime
[1:36:17] when they are built. There are
[1:36:19] variables, holders, constraints, and
[1:36:21] topos. The ones we care about in this
[1:36:22] case, we don't really care about the
[1:36:24] holders much for understanding. But the
[1:36:26] topos are lines, circles, and pictures.
[1:36:27] Pictures are just like copies of things
[1:36:29] like copies of other drawings, right? So
[1:36:32] the topos are the things that we're
[1:36:33] actually sort of the user interacting
[1:36:34] with. Um, at a higher level, the
[1:36:37] variables sometimes like they see points
[1:36:39] and things like that or text things they
[1:36:40] can edit. The topos are made up of those
[1:36:43] variables, right? A line is made up of
[1:36:45] points and then the constraints are
[1:36:48] things that you apply to them. Now, it's
[1:36:50] important to notice this is sort of you
[1:36:53] could say the opposite of encapsulation.
[1:36:56] What this structure implies is that at
[1:36:58] any time any part of the system can go
[1:37:01] looking at anything. It's almost like a
[1:37:03] complete introspection system for what's
[1:37:05] going on. A topo, for example, that is a
[1:37:09] line is not encapsulated at all. the two
[1:37:13] points that make it up are just floating
[1:37:15] in the breeze over there that you can go
[1:37:17] just grab, right? And you can do
[1:37:19] whatever you want to those points
[1:37:20] without that thing even knowing that it
[1:37:23] happened, right? So, it's almost like
[1:37:25] the most unencapsulated thing that you
[1:37:27] could possibly imagine, which is
[1:37:29] probably why it was so cool.
[1:37:32] But if we draw it,
[1:37:35] oops. Well, it kind of looks like this,
[1:37:37] right? The topos, you have a circle.
[1:37:39] It's got a radius and a center. It has
[1:37:41] pointers out to those actual things
[1:37:44] which we call variables. Those are the
[1:37:45] scalers. Those are the points. And if we
[1:37:47] have something like constraints, it's
[1:37:48] going to operate on them. It just points
[1:37:51] into those things. And all of these
[1:37:53] pointers are typically like birectional.
[1:37:55] Like that ring structure is allowing you
[1:37:57] to walk in both directions if you want
[1:37:59] to, right? But this is the way that
[1:38:01] you're actually like conceptualizing the
[1:38:03] link in those cases.
[1:38:06] Once again, the same diagram more or
[1:38:10] less than what I had to write,
[1:38:13] which is the same diagram more or less
[1:38:15] than an entity component system is
[1:38:18] because you are able to iterate over all
[1:38:21] of the properties you want to work with,
[1:38:23] which lets you implement things like a
[1:38:25] constraint or in my case a modification,
[1:38:27] right? in this generic way that operates
[1:38:31] on the pieces of things or components in
[1:38:33] any component system language in a way
[1:38:35] that doesn't require this sort of weird
[1:38:37] abstraction thought where you're trying
[1:38:38] to figure out how to get things out of
[1:38:40] something in order to work on them.
[1:38:44] That was in 1963.
[1:38:48] So to a first approximation,
[1:38:52] Ivan Sutherland was at the same level of
[1:38:57] closeness to an ND component system in
[1:38:59] 1963
[1:39:00] as I was in 1997.
[1:39:08] And then people from there
[1:39:10] didn't notice.
[1:39:12] That's the only thing I can figure out.
[1:39:14] I have not found anything except for one
[1:39:17] quote that I'll show you that explains
[1:39:20] why the heck no one realized how
[1:39:22] important this was.
[1:39:25] They didn't think about the fact that
[1:39:27] the power of this system is coming from
[1:39:30] the fact that you can look at these
[1:39:32] components of things and architect
[1:39:35] around that instead of architecting
[1:39:37] around the bag which who cares. Again,
[1:39:41] still object-oriented in its thinking.
[1:39:42] You don't have to claim it's not oop, it
[1:39:45] can still be ubo. It's just where are
[1:39:46] the encaps those encapsulation
[1:39:48] boundaries, where are the boundaries,
[1:39:50] right? Instead of looking at it and
[1:39:52] going, "Oh, the important place to put
[1:39:54] the boundary was around this. That's
[1:39:55] where the power is coming from." They're
[1:39:57] looking over here. They're like, "The
[1:39:59] power of this system was that the
[1:40:02] ability to have virtual functions on it,
[1:40:05] right? The ability to say if I want to
[1:40:07] draw this a different way, I change the
[1:40:08] sub routine." Now, I'm not trying to say
[1:40:11] that isn't useful. It's function
[1:40:13] pointers are good in certain
[1:40:14] circumstances, but what inevitably
[1:40:17] happens is they're only going to get you
[1:40:19] the simple stuff. The only reason that
[1:40:21] even worked for Southerntherland in the
[1:40:23] display case is because his display was
[1:40:26] simple. He didn't have to do things like
[1:40:28] intersecting stuff for hidden line
[1:40:29] removal or doing some kind of calling on
[1:40:31] it or who knows what. So, he could just
[1:40:34] have an abstract display function
[1:40:36] because it never interacted with any
[1:40:37] other part of the system. It's the least
[1:40:39] interesting part of this architecture.
[1:40:41] Yes, it's cool. It's Doug T. Ross's idea
[1:40:45] about Plexes. It's where it comes from,
[1:40:47] right? And that was a great idea and we
[1:40:49] should keep it. But it's not the cool
[1:40:51] part of Sketchpad at all. Right? It's
[1:40:55] the most trivial part of it. So, that is
[1:40:59] the 35-year mistake. Oops. Right? We
[1:41:03] have the answer. We could have been so
[1:41:06] far ahead if we just studied that and
[1:41:08] figured that out because it's so much
[1:41:10] more powerful to think about systems
[1:41:11] that way especially the hardest kinds of
[1:41:14] systems like editors.
[1:41:17] This is the quote I was talking about.
[1:41:19] So you can see here this is Alen K,
[1:41:23] father of small talk
[1:41:26] and this quote breaks my heart because I
[1:41:28] like Alen K. I think everyone likes Alen
[1:41:30] K probably. I don't know maybe not
[1:41:32] probably someone out there who hates
[1:41:33] Alen K. Alan K is very sorry. He was
[1:41:35] trying all sid kinds of cool things.
[1:41:37] Xerox Park is awesome. I'm not gonna say
[1:41:39] something negative about Alen K. I'm
[1:41:40] just not gonna do it.
[1:41:43] This quote breaks my heart because what
[1:41:44] he says in this quote is basically that
[1:41:48] the constraint solver which he obviously
[1:41:51] knew about. So he because I happen to
[1:41:54] know that Alen K read the thesis that's
[1:41:56] documented. Alan K says he read the
[1:41:57] thesis and he paid attention to the
[1:42:00] constraint solver part and he paid
[1:42:02] attention to it enough to know that what
[1:42:04] he called it omnisient he was calling it
[1:42:07] omnisient right this idea that it could
[1:42:10] look at the properties like that and
[1:42:12] work on them and K thinks it's a bad
[1:42:15] thing right he says hey there's this
[1:42:18] thing called Alan Bing's thing lab which
[1:42:20] is another program that was made later a
[1:42:21] first attempt to go beyond touchpad and
[1:42:23] he devised a nice approach for dealing
[1:42:25] with constraints that didn't require ire
[1:42:26] the solver to be omnicient.
[1:42:29] The omnicient part was the good part,
[1:42:31] right? That was the thing that was so
[1:42:34] powerful. It's why it's kind of
[1:42:35] torturous to make things in small talk.
[1:42:37] I have dabbled in it a little bit. It's
[1:42:39] like no, the encapsulation needs to be
[1:42:42] in the right place. You don't want to
[1:42:43] think of everything as these small
[1:42:44] little objects. So why did they why was
[1:42:47] Alen K so focused on that stuff? Why was
[1:42:49] Strus so focused on that stuff? And
[1:42:52] honestly, from reading it, oops, didn't
[1:42:55] mean to advance there or to go back
[1:42:57] there. From reading it, this is my best
[1:43:00] guess. Their backgrounds predisposed
[1:43:04] them not to want this, right? You look
[1:43:07] at where they come from. Strus comes
[1:43:10] from distributed systems. Alan K had a
[1:43:12] degree in molecular biology. They're
[1:43:14] both thinking of little tiny cells that
[1:43:18] communicate back and forth but which do
[1:43:20] not reach across into each other's
[1:43:22] domain to do different things. And so
[1:43:25] they're certain Allen K especially that
[1:43:29] that is the future of how we will
[1:43:31] engineer things. They're going to be
[1:43:33] like microorganisms where they're little
[1:43:35] things that we instance, right? And they
[1:43:38] just talk to each other. So everything
[1:43:39] will be built that way from the ground
[1:43:41] up.
[1:43:43] But the problem with that is it doesn't
[1:43:45] seem to work in practice. It's a great
[1:43:48] idea when thinking about systems that
[1:43:50] are actually separated in that way like
[1:43:52] actual computers talking over a network.
[1:43:54] It makes perfect sense because they do
[1:43:56] look like microorgans. And most of Alen
[1:43:58] K's ideas actually map very well to
[1:44:00] things like the internet at large where
[1:44:02] you really do have to just pass messages
[1:44:04] back and forth. So again, not going to
[1:44:06] say something negative about Alen K. The
[1:44:08] ideas are good and they do have very
[1:44:10] good applications. It's it's smart. It
[1:44:13] really is. But when you're talking about
[1:44:15] code that's working inside one computer
[1:44:18] in the same core memory that's meant to
[1:44:20] work together, it's too limiting. It's
[1:44:22] way too limiting. It's not the right
[1:44:24] model and it forces us to do way too
[1:44:26] much work to accomplish the same thing.
[1:44:30] So just to underscore,
[1:44:34] reading this history actually gave me a
[1:44:36] nice perspective on these things. And I
[1:44:38] think there's reasons why C++ was
[1:44:40] adopted even after all the stuff I just
[1:44:41] said about how the compile time hard
[1:44:43] stuff wasn't very good. One of the
[1:44:44] things that I didn't really appreciate
[1:44:46] was it kind of sounds to me like shrusup
[1:44:48] was really important in getting type
[1:44:50] checking for us. Like C did not even
[1:44:53] type check function calls at the time
[1:44:56] that was making C with classes, right?
[1:44:59] And he recognized because of his
[1:45:01] background in simula. He's like this is
[1:45:03] ridiculous. I think he gave an example
[1:45:05] like if I do square root like sqrt in C
[1:45:08] parenthesis 2
[1:45:11] that doesn't work right now because it
[1:45:13] passes the integer too and it doesn't
[1:45:14] check that square roots taken a double
[1:45:16] or something right or whatever it was
[1:45:18] taking in that particular version of the
[1:45:19] library he was using. He's like that
[1:45:22] cannot be something that we have to
[1:45:23] catch at runtime. Especially not in
[1:45:25] those days when debuggers are worse and
[1:45:27] everything is worse, right? Iteration
[1:45:29] time is slower. So you get this
[1:45:31] situation where you're like, I kind of
[1:45:33] see why these things took off. Some of
[1:45:36] these things like the compile time, you
[1:45:37] know, encapsulation hierarchies, they're
[1:45:39] coming in at the same time that C++ is
[1:45:42] making positive contributions that
[1:45:44] actually do help you program for real,
[1:45:46] right? And it's not like we can't think
[1:45:48] of uses for things like virtual
[1:45:50] functioning classes like interfaces just
[1:45:53] that bare concept is a place where we
[1:45:55] still use those things today even new
[1:45:57] languages those things. So there there
[1:45:58] is that too if it's used responsively,
[1:46:01] right? It's just that compile time
[1:46:03] hierarchy that was a problem. And this
[1:46:04] is a quote that I also want to include
[1:46:06] just to give credit. He's also on the
[1:46:08] same team. He wants the fast thing,
[1:46:11] right, to be easy for people to do. You
[1:46:14] don't want your definition of good code
[1:46:16] to be slow, right? So anyway, when you
[1:46:19] read through all this stuff, you you're
[1:46:21] kind of rooting for everybody. To be
[1:46:22] completely honest, even after all the
[1:46:24] suffering that C++ has caused me in my
[1:46:26] life, I was kind of like, "Oh, all
[1:46:27] right. I get it. I get it, man. I do."
[1:46:31] So, that's the 35-year mistake is the
[1:46:33] distance between those two years. The
[1:46:35] year in which we could have had the
[1:46:36] entity component system because the
[1:46:38] first person has sort of done something
[1:46:39] that was almost that and the year in
[1:46:40] which we actually got the entity
[1:46:41] component system, which I'm not even
[1:46:44] saying is a good design or not. I don't
[1:46:45] even have an opinion on something like
[1:46:46] that to be completely honest with you.
[1:46:49] But I think it was a really cool idea
[1:46:50] and an interesting architectural idea to
[1:46:52] explore. And so I'm really glad that we
[1:46:54] got there either way. But I wish we
[1:46:56] could have gotten there a little bit
[1:46:57] sooner.
[1:46:58] So unfortunately the mistake if that's
[1:47:01] 35 years, it does unfortunately not end
[1:47:04] there because if you do a search on
[1:47:06] Google right now and you're like, I need
[1:47:08] an oop tutorial. I need an
[1:47:10] object-oriented programming tutorial.
[1:47:12] What will you see? Hit number one, we'll
[1:47:15] have a domain model that has
[1:47:17] encapsulation that matches you or sorry,
[1:47:19] you'll have a compile time hierarchy
[1:47:20] that matches the domain model exactly
[1:47:22] like we don't want. This person imagines
[1:47:24] this is the number one hit. He imagines
[1:47:27] something called a special Iron Man
[1:47:29] that's slightly different from a regular
[1:47:30] Iron Man because I guess in his mind or
[1:47:33] whoever wrote it, I don't even know. It
[1:47:34] might be a team of people.
[1:47:37] There's some kind of a specialized Iron
[1:47:39] Man that I didn't I mean, I don't read
[1:47:40] comics. Maybe that's a thing. Hit number
[1:47:43] two, Java. OOP. This is from W3 schools.
[1:47:47] Again, not only is it a compile time
[1:47:50] hierarchy that matches the domain model,
[1:47:52] but it's one of the ones that you can
[1:47:54] actually find in those early papers.
[1:47:56] Strus talks about vehicle sending cars.
[1:47:58] And if you remember, cars crossing a
[1:48:00] bridge, it could be trucks or buses was
[1:48:02] in Simula day one. It's where they came
[1:48:04] up with that subclassing thing that they
[1:48:06] were going to do. So, we're still
[1:48:08] pushing it today on hit number two. Hit
[1:48:10] number three is three types of bicycle
[1:48:13] that come off a bicycle, right?
[1:48:17] And don't ask me why there's spaces in
[1:48:19] that and not in the mountain. I mean, I
[1:48:21] don't even know. That's the top three
[1:48:23] hits. I stopped looking after that
[1:48:24] because I'm just like I give up. So, one
[1:48:27] thing that we could do to keep this
[1:48:30] mistake from propagating is just get
[1:48:32] this idea out there that compile time
[1:48:34] hierarchies of encapsulation that match
[1:48:36] the domain model are not that good.
[1:48:39] Sometimes they work like with
[1:48:40] distributed systems or maybe
[1:48:42] microbiology, but a lot of times they're
[1:48:44] just more work than they're worth. And
[1:48:47] that would help. It would help a lot.
[1:48:50] And I would bolster that here finally
[1:48:54] the end of the talk with this quote,
[1:48:56] which I think is the best one to end on.
[1:48:58] It's that the most treacherous metaphors
[1:48:59] are the ones that seem to work for a
[1:49:01] time because they can keep more powerful
[1:49:04] insights from bubbling up. Right? We got
[1:49:06] this thing in place. There was this
[1:49:08] compile time hierarchy that matched the
[1:49:09] domain model idea and it was stopping
[1:49:12] all of our other architectural
[1:49:14] development because everyone was saying
[1:49:15] it was going to work and it was going to
[1:49:16] be great and we must be doing it wrong,
[1:49:19] right? But actually that wasn't the
[1:49:21] case. And
[1:49:24] this is a hard quote to find. If you
[1:49:26] search for it, I'm not sure if you will
[1:49:27] find it, but if you read through, you
[1:49:29] will find it. It comes from Alan K. He's
[1:49:32] the one who said it, right? That's him
[1:49:34] sitting at his uh you know I think that
[1:49:36] must be uh one of the original Palo Alto
[1:49:38] computers right the Alto I think is what
[1:49:40] that one is from Xerox Park.
[1:49:43] So that's the actual end of my talk.
[1:49:45] Thanks everyone for listening. I'm
[1:49:47] surprised I was able to remember all
[1:49:48] that stuff for this. You've been a
[1:49:50] wonderful audience and uh I guess now
[1:49:53] Ryan Flurry will be coming up on stage
[1:49:55] to uh interview me and take questions
[1:49:58] from the audience. Is this correct? Sam.
[1:50:02] >> What? Sam, is that true?
[1:50:03] >> I say it again.
[1:50:06] >> The organizer, ladies and gentlemen,
[1:50:12] >> please welcome to the stage Ryan Flurry.
[1:50:14] Everyone
[1:50:23] Okay. Well, yeah, thank you for that
[1:50:25] talk. That was really good.
[1:50:27] >> It was a lot of fun putting together.
[1:50:28] >> Yeah. So, um I guess the first comment
[1:50:33] that I would have is that it seems like
[1:50:36] uh I'm a little bit glad to see that
[1:50:39] people in the six There's two things.
[1:50:41] I'm glad to see that people in the 60s
[1:50:42] were like
[1:50:44] using these techniques that seem to be
[1:50:46] reemergent. It kind of makes it feel
[1:50:48] like there's like uh maybe like some
[1:50:51] degree of gaslighting since then. Like
[1:50:53] there's like all these you rediscover
[1:50:55] these things, they seem to be useful.
[1:50:57] Um, and then for some reason like uh we
[1:51:01] haven't actually
[1:51:04] that information has been lost I guess.
[1:51:06] Do do you find I mean I assume you find
[1:51:08] the same thing to be true. Uh yeah. I
[1:51:10] mean I I guess the problem so I don't
[1:51:13] even know if it's like gaslighting in
[1:51:15] that sense, right? Because it's like I
[1:51:17] don't necessarily know I didn't find a
[1:51:19] lot of evidence that people were like
[1:51:20] intentionally obviously like it wasn't
[1:51:21] like somebody was like I would rather
[1:51:23] promote my thing than this thing in
[1:51:24] sketchpad that I noticed. That quote
[1:51:27] from Alan K is kind of instructive in
[1:51:29] this case. He honestly believed that
[1:51:32] having the thing be omnisient was bad.
[1:51:34] He's saying that this is bad. Right? And
[1:51:37] you see the same thing from Strereip
[1:51:39] saying that this you know switch you
[1:51:41] know this basically switch on a type is
[1:51:42] bad. And so I I think they just honestly
[1:51:45] believed that they they believe that
[1:51:47] these were bad for modularity and in
[1:51:49] their minds because they're so focused
[1:51:50] on the modularity.
[1:51:52] They were just saying this isn't good
[1:51:54] and so it just kind of doesn't get
[1:51:56] propagated. This is this thing that you
[1:51:58] see all the time right? If someone isn't
[1:51:59] a good PR isn't good PR for their thing
[1:52:01] it doesn't get propagated.
[1:52:03] >> Yeah that makes sense.
[1:52:06] So um in your own personal programming
[1:52:09] like journey you started with like
[1:52:11] learning the traditional object-oriented
[1:52:14] sort of or like C++ templatization of uh
[1:52:17] compile time hierarchies of
[1:52:19] encapsulation and so on. you uh I mean I
[1:52:24] I have an idea of where you changed or
[1:52:27] where you developed but I'm curious
[1:52:29] about where you learned to not do that
[1:52:32] and furthermore
[1:52:34] from where you learned it where did they
[1:52:36] learn not to do it did they did they
[1:52:38] learn from the original papers or did
[1:52:40] the simple ideas just reemerge or what
[1:52:42] what is the story there
[1:52:44] >> uh so that's kind of interesting so when
[1:52:48] I was younger like so when I started
[1:52:50] programming when I was very little
[1:52:51] Right. I didn't know any of the things.
[1:52:53] I wouldn't know anything about
[1:52:54] architecture. C++ wasn't even invented
[1:52:56] uh in the in I don't think would it have
[1:52:58] been invented? So C so C with classes
[1:53:01] would have been but C++ wasn't even like
[1:53:03] out in the world the time when I would
[1:53:04] have started in like basic or something
[1:53:06] like that, right? So I definitely uh
[1:53:08] started without any of these notions.
[1:53:10] But then when I first went out into like
[1:53:13] you know professional I mean my first
[1:53:15] job was hardly professional but when I
[1:53:18] went out into the world of like
[1:53:18] commercial programming uh I I definitely
[1:53:22] like thought that everyone was
[1:53:23] presumably right about this. I just
[1:53:25] didn't know. And so I tried programming
[1:53:27] in this model and learned all those
[1:53:29] things because you know it kind of has a
[1:53:30] magic the gathering feel to it. It's
[1:53:32] like you're learning a lot of intricacy
[1:53:34] and it's just magic the gathering. It's
[1:53:36] something people made up that was
[1:53:37] fictional but you you know you don't
[1:53:39] know that. you think it's real, right?
[1:53:40] But you're getting into it in the same
[1:53:41] way you might get into Magic the
[1:53:42] Gathering, like, "Oh, I figured out that
[1:53:44] the template can do this thing
[1:53:45] >> and it becomes its own little game,
[1:53:47] right?" So, I think it kind of went that
[1:53:49] way for me. And at the time, it was very
[1:53:51] obvious that this was stupid. Like, if I
[1:53:53] had actually thought about it, but I
[1:53:54] chocked it up to me just not knowing how
[1:53:56] to do it, right? Which I don't think was
[1:53:57] actually true. I think it was just like,
[1:53:58] "No, these are actually just worse than
[1:53:59] what you were doing." Because what I
[1:54:01] noticed was things that would have taken
[1:54:03] me only a few days before were taking
[1:54:05] like months to like figure out all of
[1:54:07] the ways that I would have to do it in
[1:54:09] order to make it fit these things. And I
[1:54:11] think I was just too stupid to realize
[1:54:12] that probably just means it's just a bad
[1:54:14] approach, right?
[1:54:16] >> Uh so you had a second part of the
[1:54:17] question which was how did I undo it?
[1:54:19] That part is a little more concerning I
[1:54:22] guess because the only reason that
[1:54:24] happened was I happened to then program
[1:54:26] with people who had never done that. So
[1:54:28] they were people who never had the
[1:54:30] experience of being told to do this
[1:54:31] architecture or just ignored it and
[1:54:33] continued to program the old school way.
[1:54:34] And I was like, "Oh, these people are
[1:54:37] very successful and very important
[1:54:39] programmers. So maybe it's not the case
[1:54:41] that I just don't understand it. Maybe
[1:54:43] there's actually something to keeping
[1:54:44] doing this way." The reason that's more
[1:54:46] concerning to me is it's like it means
[1:54:47] if those people aren't around,
[1:54:49] >> if they weren't around, maybe I wouldn't
[1:54:51] never had that experience, right? And so
[1:54:52] you kind of need this generational
[1:54:54] overlap of people who still remember the
[1:54:56] good things about the previous way to
[1:54:58] tell you that the new way kind of sucks,
[1:55:00] right?
[1:55:01] >> And do you know like um when you worked
[1:55:03] with those other programmers, were they
[1:55:06] were they informed by this older
[1:55:07] generation like the 1960s papers of how
[1:55:09] they were doing these things? Did they
[1:55:11] just take those lessons or
[1:55:14] >> No, I think it's just a case of like the
[1:55:18] if you were using programming resources
[1:55:21] from that era of even just the 1970s,
[1:55:25] you wouldn't be seeing like it was more
[1:55:27] academic the places where oop would have
[1:55:29] been talked about, right? Small talk was
[1:55:31] a thing that would have been in research
[1:55:33] stuff, right? And simula was a thing
[1:55:35] with papers and stuff like that. But the
[1:55:37] person who learns to program like you
[1:55:39] know in the game industry and stuff like
[1:55:40] that the person who learns to program on
[1:55:41] an Apple 2 is not being exposed to those
[1:55:43] things right so they just learned in an
[1:55:45] environment and using reference
[1:55:47] materials that did presumably kind of
[1:55:49] come through that culture but it wasn't
[1:55:51] like they were you nobody was like oh
[1:55:53] yeah Doug T Ross man and plexes like
[1:55:55] that's that's the stuff right it's like
[1:55:57] no like so I think it's just more that
[1:56:00] they hadn't have had that that idea
[1:56:02] pushed down on them in a way that they
[1:56:04] believed.
[1:56:05] >> Okay. Um, so, uh, I had it in my head,
[1:56:10] but I got to check my notes here. Um,
[1:56:13] so I think that I'm I was curious about
[1:56:16] I have a collection of like not exactly
[1:56:19] related questions or discussions like
[1:56:21] >> hit me.
[1:56:22] >> So, one of the thing you introduced this
[1:56:24] subject by saying like one of the
[1:56:26] arguments that people will use to
[1:56:28] promote like sort of object-oriented
[1:56:30] these or I shouldn't say
[1:56:31] object-oriented, I should say compile
[1:56:33] time hierarchies. If someone out there
[1:56:35] wants to come up with a catchy moniker
[1:56:36] for that, it is hard to say. So, we need
[1:56:39] something like oop for that, right? And
[1:56:41] uh and it would be nice because again,
[1:56:42] like I said, I think it's pretty
[1:56:44] important
[1:56:45] >> to draw that distinction because like
[1:56:48] like Mach who I quoted at the beginning
[1:56:50] of the thing who did that entity
[1:56:51] component system, he's like he's
[1:56:53] thinking of it in terms of
[1:56:54] object-oriented. He's not thinking this
[1:56:56] is not object-oriented, right? So you
[1:56:58] can still you can easily call yourself
[1:57:00] an object-oriented programmer and want
[1:57:01] object-oriented principles to apply to
[1:57:03] your codebase and just not think about
[1:57:05] that compile time thing. And it seems to
[1:57:07] work pretty well.
[1:57:09] >> Yeah, it kind of seemed like um the
[1:57:11] object-oriented part of drawing
[1:57:13] boundaries, it doesn't actually it's not
[1:57:15] um it might be descriptive of a system,
[1:57:17] but it's not prescribing like where to
[1:57:19] put those boundaries. Exactly.
[1:57:21] >> Yes. Exactly. And also furthermore, it's
[1:57:23] something I think we could all agree
[1:57:24] about, right? I don't know that a a
[1:57:26] hardcore object-oriented uh person like
[1:57:29] certainly not Alan K probably would
[1:57:31] never agree that making like an API
[1:57:33] boundary around something was that
[1:57:35] object-oriented if the thing was fairly
[1:57:37] large although he might but we can all
[1:57:40] agree that that's a thing we want to do
[1:57:42] like I don't consider myself an
[1:57:43] object-oriented programmer but I
[1:57:45] consider that to be a good thing to do
[1:57:46] and I think that's certainly a point of
[1:57:47] commonality and I think most
[1:57:49] object-oriented programmers would call
[1:57:50] that an object-oriented thing to do even
[1:57:53] though it really predates that you could
[1:57:55] just think of objective programming one
[1:57:57] of the principles is sort of
[1:57:58] crystallizing that idea into one of
[1:58:00] their core concepts and I think that's a
[1:58:02] good core tenant to have right to do
[1:58:04] that at the appropriate size that's
[1:58:06] where I tend to part ways like what that
[1:58:08] size is
[1:58:09] >> so on the large team subject you were
[1:58:12] digging through all these historical
[1:58:14] papers and records and everything did
[1:58:16] you actually find any research about
[1:58:17] what people actually do for large teams
[1:58:20] >> so one of the things is I was focused on
[1:58:22] figuring out where these ideas came
[1:58:24] from. So I didn't go looking for where
[1:58:26] the I don't want to call them excuses.
[1:58:28] It's too disparaging, but where the
[1:58:31] justifications came from, right? So I
[1:58:34] what I can tell you so I don't know
[1:58:36] that's another that'd be a whole another
[1:58:37] topic. This thing took two hours or
[1:58:38] something like that, right? So that's a
[1:58:41] whole another question. It would be very
[1:58:42] interesting to answer. But what I can
[1:58:45] tell you is during the course of the
[1:58:47] development of these core ideas, I never
[1:58:50] once saw anyone talk about that. And
[1:58:54] they were always like one person doing a
[1:58:57] team doing things by themselves or two
[1:58:59] people developing things by themselves.
[1:59:01] And to the extent that like larger teams
[1:59:03] would have been involved at all, it
[1:59:04] might have been on the simulus side.
[1:59:05] like some of their opinions may have
[1:59:07] been influenced by uh you know in ways
[1:59:10] that they didn't directly like they
[1:59:11] didn't attribute any of those things to
[1:59:13] it but maybe they were seeing people use
[1:59:15] simul in the world had something to do
[1:59:17] it but I don't think there were that
[1:59:18] large teams working on simula either I
[1:59:19] don't know
[1:59:20] >> yeah it's kind of interesting alone that
[1:59:22] the the history of computing it's always
[1:59:25] large team or small teams pushing large
[1:59:27] improvements like successively so it's
[1:59:29] interesting to optimize for large teams
[1:59:31] that in that way but
[1:59:33] >> well and you might even say it creates a
[1:59:34] bit of a problem because it means that
[1:59:36] like if the innovation happens in small
[1:59:38] teams, but we do need large teams uh of
[1:59:40] people to do certain things, it's like
[1:59:42] it's kind of hard to figure out where
[1:59:43] the innovation in that comes from
[1:59:44] because if our risk comes these few
[1:59:46] people doing something, they're not
[1:59:48] having the same experience as a large
[1:59:49] team. So maybe it's like small teams
[1:59:51] doing something on the side of a big
[1:59:53] team is where we get some of that
[1:59:54] innovation. I don't know.
[1:59:55] >> Yeah. Um, so I'm kind of curious about
[1:59:59] like so a few uh programming ideas that
[2:00:03] a lot of people use like that you
[2:00:05] regularly use in your in your
[2:00:07] programming came up. One being like
[2:00:09] discriminated unions or tag unions um as
[2:00:12] sort of like forming this like mutually
[2:00:14] exclusive branching structure um as
[2:00:16] opposed to uh like the fatstruct model
[2:00:19] where it's like a comp just it's one
[2:00:22] unified type. I'm I'm kind of interested
[2:00:25] to hear like what you think about like
[2:00:29] um both of those things are you've said
[2:00:31] are like good in their respective
[2:00:33] situations. I'm curious about like when
[2:00:35] you know that introducing boundaries of
[2:00:38] mutual exclusion like in a discriminated
[2:00:40] type is useful whereas the uh the the
[2:00:43] sort of uh large fatstruct thing stops
[2:00:46] being useful in those cases.
[2:00:47] >> So I don't really think of them as
[2:00:48] distinct. I think of them as sort of the
[2:00:50] same things. I'm just trying to use
[2:00:52] terms that other people think in to
[2:00:53] communicate that. So the way that I
[2:00:55] normally think about it is there are two
[2:00:57] types of situations I might find myself
[2:00:59] in. One is where the domain model itself
[2:01:03] like literally the thing is telling me
[2:01:06] clearly that these things are mutually
[2:01:08] exclusive and that might be a place
[2:01:10] where I you know have more in common
[2:01:13] with the oop side of things because I'm
[2:01:15] like I see why you guys are thinking
[2:01:16] about if that was true about this thing.
[2:01:19] So in those cases I would use a
[2:01:20] discriminated union because I prefer to
[2:01:22] write code in like a verb oriented way
[2:01:24] not an object-oriented way. So I but I'm
[2:01:26] just doing the flip side of what they're
[2:01:27] doing with their virtual function in
[2:01:28] those cases right I just think it works
[2:01:30] out better in my way but that's just you
[2:01:32] know that's my personal opinion. It also
[2:01:33] has to do with what type of system
[2:01:34] you're making whether or not people are
[2:01:36] going to be adding types to the system
[2:01:37] more frequently or whether they're going
[2:01:38] to be adding actions. I tend to find
[2:01:40] that people add actions more frequently.
[2:01:41] That's why I focus on that. But either
[2:01:43] way
[2:01:43] >> that makes sense.
[2:01:45] So if I can see that this is by
[2:01:47] definition mutually exclusive then I'm
[2:01:49] discriminated union and the reason for
[2:01:51] that is exact same reason for true strip
[2:01:53] and everybody else to catch errors. I
[2:01:56] don't want to be using I don't want to
[2:01:58] make that a fatty strruct where I'm
[2:01:59] accidentally doing code that's going to
[2:02:01] do both things. So I try to basically
[2:02:03] replicate that simul style thing or
[2:02:05] really it's it's Tony Horses right sir
[2:02:07] Tony idea of of that I try to
[2:02:10] replicate that and it's just
[2:02:11] unfortunately C++ has doesn't really
[2:02:12] have good support for that like I said
[2:02:13] Santa very is not very good in my
[2:02:15] opinion the real thing that Tony Horror
[2:02:18] wanted would would have been great so I
[2:02:20] would love that feature the fatty
[2:02:22] strruct qua fatty strruct and like I
[2:02:24] said I mix these two together so I don't
[2:02:25] think it's that distinct to me but the
[2:02:27] idea of like feature flags or something
[2:02:29] like that right like I'm going to hit
[2:02:30] this bit and then it means that this
[2:02:31] path might be taken. What the Plex guy
[2:02:33] uh right what what Doug T. Ross would
[2:02:35] have called those like switches, right?
[2:02:39] That to me is for mixin as they call it,
[2:02:41] right? When I know I'm combining lots of
[2:02:43] things together, right? Like a tasty
[2:02:44] stew that's going to be delicious and
[2:02:46] it's going to taste fabulous when you
[2:02:47] use these entities, right? That's that's
[2:02:50] when I reach for that. And I think those
[2:02:51] are really they're very simple. You can
[2:02:53] teach them to someone in an afternoon
[2:02:56] and they can apply them pretty directly
[2:02:58] right away. And that's one of the
[2:02:59] reasons why I think they're so much
[2:03:00] better than things like the compile time
[2:03:02] hierarchies where, you know, I've seen
[2:03:03] programmers tie themselves in knots and
[2:03:05] spend months trying to do something that
[2:03:06] literally that approach would it would
[2:03:07] take in 30 minutes.
[2:03:08] >> Yeah.
[2:03:08] >> Right. Yeah.
[2:03:10] >> And I I'm I'm a little confused about
[2:03:12] the uh like
[2:03:15] exactly what so looking glass you
[2:03:17] introduced them as using like sort of
[2:03:18] the faststruct model, but it sounded
[2:03:20] like they ended up with a entity like
[2:03:22] component system thing where they split
[2:03:24] everything out into like they they
[2:03:26] pulled out common parts of entities and
[2:03:27] put them isolated their storage. Did
[2:03:29] they make that transition or did they
[2:03:31] use one early and then the second later?
[2:03:33] >> Uh can I ask a question to the audience?
[2:03:36] >> Yes. Sam, how much time we got?
[2:03:39] >> We still have time right now. Maybe
[2:03:42] Well, it depends. There are multiple
[2:03:44] paths that could be taken. And the the
[2:03:47] the split point is in about 25 minutes.
[2:03:51] >> Uh, how badly do you want a complete
[2:03:54] version of that answer versus a
[2:03:56] summary answer? Because I can answer
[2:03:58] that very accurately.
[2:04:00] >> Okay. Um, yeah, let's go with the
[2:04:03] accurate one. Okay. All right.
[2:04:06] [Applause]
[2:04:13] deleted scenes to keep this talk uh
[2:04:17] somewhat under two hours, which
[2:04:18] hopefully we did and now won't do. So,
[2:04:22] I'll skip some of this just to keep it
[2:04:23] relatively quick. So, inside Ultima
[2:04:26] Underworld, an entity was basically a
[2:04:29] fatty strruct overlay. So the way that
[2:04:32] it worked is you had an entity and then
[2:04:34] if there were two separate things like
[2:04:36] hit points and fuel that were generally
[2:04:39] mutually exclusive, meaning an entity
[2:04:41] probably can't have both of them because
[2:04:43] fuel is used only for like lanterns and
[2:04:46] and lanterns don't have hit points, then
[2:04:47] we'd put them in the same place,
[2:04:49] >> right? That was that was uh Ultima
[2:04:51] Underworld, right? And of course, this
[2:04:54] is, you know, rough because it's like it
[2:04:56] means that when you're accessing one of
[2:04:57] these, you're secretly also accessing
[2:04:59] the other, right? because they're in the
[2:05:01] same place. And so you could have an
[2:05:03] error where you were doing something
[2:05:04] where like you're checking the fuel or
[2:05:06] you're checking the hit points. In this
[2:05:08] case, like you're checking the hit
[2:05:09] points, but you're secretly checking the
[2:05:10] fuel. And then you delete the entity,
[2:05:12] you know, because that's what it was
[2:05:13] thinking, right? And this is Mach. He
[2:05:15] didn't his picture didn't make it in.
[2:05:17] I'm glad I get to show him now. He's the
[2:05:18] guy who did a lot of the implementation
[2:05:20] on the dark object system. He came on
[2:05:22] the scene in Ultima Underworld 2 and
[2:05:25] he's the one who coined that phrase that
[2:05:26] that quote I put up. That's him, the
[2:05:28] compile time harchy. He's the one who
[2:05:29] crystallized that, right? He comes on
[2:05:32] cuz the uh in the earlier earlier ones
[2:05:34] like it was Doug Church and Dan Schmidt
[2:05:36] and a bunch of people who did Ultima
[2:05:37] Underworld one. He comes on of
[2:05:39] Underworld 2 and he actually literally
[2:05:42] had the that bug that fuel bug. He wrote
[2:05:44] a thing for damage where if you threw an
[2:05:46] empty lantern at a wall, it would enter
[2:05:49] the damage system because it was
[2:05:50] supposed to take damage from hitting the
[2:05:51] wall. And it would be like, "How many
[2:05:52] hit points does the lantern have?" It'd
[2:05:53] be like zero. It's like, "Well, I guess
[2:05:55] it's out of here." And so empty lanterns
[2:05:57] thrown at walls would just disappear.
[2:05:58] Nice.
[2:05:59] >> Right. And so he had to fix that bug by
[2:06:01] doing exactly what you'd expect. He'd
[2:06:02] have to like check, you have to manually
[2:06:04] add that code.
[2:06:05] >> Yeah.
[2:06:05] >> And so, you know, they didn't like this
[2:06:07] because remember these guys and again,
[2:06:09] much like, you know, Ivan Sutherland and
[2:06:11] Doug Ross, these guys were super smart
[2:06:12] MIT people and and Sutherland's also
[2:06:14] Carnegie Melon and Caltech, right? It's
[2:06:16] like kind of nuts going through the
[2:06:18] whole gauntlet there. Uh the folks at
[2:06:19] Looking Glass are MIT graduates. They're
[2:06:21] super super smart guys. They do all this
[2:06:23] amazing stuff. So, they don't want to
[2:06:25] they don't want to have this happen,
[2:06:26] right? they just don't know what else to
[2:06:28] do because they have these like really
[2:06:29] hardcore memory constraints.
[2:06:30] >> Yep.
[2:06:31] >> And furthermore, they talk a lot about
[2:06:33] the um the sort of uh trade-offs you
[2:06:36] have to make. So, if you have a fuel
[2:06:38] system that needs to store stuff and you
[2:06:39] have a combat system that needs to store
[2:06:40] stuff and you do make space for them, um
[2:06:42] it means that if you do, you know, if
[2:06:44] you're using that overlap, it means that
[2:06:47] if you then decide you need an entity
[2:06:48] that has combat and fuel because we
[2:06:50] wanted to add that, it's like crap, I've
[2:06:52] got this overlap, I can't do it. So now
[2:06:55] I have to make a trade-off like maybe I
[2:06:57] shrink the amount of data that the
[2:06:58] combat system can store and that sucks
[2:07:00] right because now I'm forced into this
[2:07:02] this decision I didn't want to have to
[2:07:03] make and that's just you know what the
[2:07:05] kind of situation they're working on
[2:07:07] working under the kind of constraints
[2:07:08] they're working under when they go to do
[2:07:09] System Shock which is the RPG. So they
[2:07:12] do Ultimal Underworld one two and they
[2:07:14] do System Shock. I'm just following
[2:07:15] their lanes. They also they have
[2:07:16] Pteranova and Flight Unlimited which I
[2:07:17] won't cover because they're not the same
[2:07:18] uh in terms of like lineage really for
[2:07:20] the teams and how they were uh doing
[2:07:21] RPGs. This is just the RPGs from looking
[2:07:23] glass. Um, so yeah, it kind of looks
[2:07:26] like that. I'll skip this because it's
[2:07:28] not part talk. Uh, they go to an
[2:07:29] outlinking kind of structure. So what
[2:07:31] they do is they say, "All right, we we
[2:07:32] kind of want something better than that.
[2:07:33] So we're going to do is we'll have our
[2:07:35] entities. We have a little bit more
[2:07:36] memory to work with now. So we'll have
[2:07:37] the entities have their shared part up
[2:07:39] front that everyone roughly has. So it's
[2:07:41] kind of fatty but not that fatty. And
[2:07:44] then everybody gets one pointer out to
[2:07:46] something, right? and we'll try to make
[2:07:48] those things be things that don't have
[2:07:50] to combine together, but it's still a
[2:07:51] limitation, right? Because they can't
[2:07:52] have two of them, which they would have
[2:07:53] liked to have had. So that's how they
[2:07:55] got there. That's that's what system
[2:07:56] shock was. It was like one outlink per
[2:07:58] entity that could extend it.
[2:08:00] >> Got it.
[2:08:00] >> And now that solves their growing
[2:08:02] problem, right? It's like we can just
[2:08:03] grow things arbitrarily and they don't
[2:08:05] like overlap some unrelated system or
[2:08:07] something like that, but it doesn't
[2:08:08] really allow them to combine them in
[2:08:09] that way that they would have liked. So
[2:08:10] it's still almost the same limitation.
[2:08:12] It's just more of a memory optimization
[2:08:14] at this point, right?
[2:08:15] Um, but it also catches this error
[2:08:18] because now you sort of have a
[2:08:19] discriminated union going on. So you
[2:08:21] can't access fuel off the base entity
[2:08:23] because it doesn't have it. So you have
[2:08:24] to do something like this where like if
[2:08:25] it's a light source I can get the light
[2:08:27] source or better yet I can only return a
[2:08:29] light source pointer if it was a light
[2:08:31] source. And so then I it's kind of more
[2:08:33] foolproof that I can just check one
[2:08:35] pointer and good to go. Right? Again I'm
[2:08:37] blowing through these but yeah this was
[2:08:38] me making fun of standard variant. Yeah.
[2:08:40] Um, so, uh, Flight Unlimited, this was
[2:08:43] I'm just going into this because it it
[2:08:44] sets up the entity component system
[2:08:46] thing. Flight Unlimited actually had,
[2:08:48] uh, it was the first thing to use C++
[2:08:50] really heavily in the company. And so,
[2:08:51] they were using new and delete like
[2:08:52] you're supposed to do in C++. And
[2:08:54] unfortunately, that totally fragmented
[2:08:56] memory. Totally like thrashed out memory
[2:08:57] and fragmented memory. So, uh, I don't
[2:09:00] know if this is well known, but
[2:09:01] basically Fight Unlimited is a game
[2:09:02] where you like fly around, you know, in
[2:09:03] the thing and and whatever. It was very
[2:09:05] popular flight at the time, actually.
[2:09:07] Uh, and you'll notice that in the
[2:09:08] cockpit here there's gauges, but there's
[2:09:11] no fuel gauge, right? There's no fuel
[2:09:12] gauge on there. It's just it's other
[2:09:14] stuff. There's no fuel gauge at all. But
[2:09:17] sometimes it would say out of fuel would
[2:09:19] just be like out of fuel, right? And
[2:09:21] what out of fuel was was actually the
[2:09:23] memory is too fragmented. So what it
[2:09:25] would do is it would say out of fuel, it
[2:09:28] would clo it had like a an executable
[2:09:30] that was sort of running as sort of a
[2:09:32] batch restarter for the main executable.
[2:09:34] it would just close the whole rest of
[2:09:36] the executable. So you save the game
[2:09:38] state, close the executable, reload the
[2:09:41] game state, and you know, then you were
[2:09:43] there you're back to good. Uh this is
[2:09:46] Tom Leonard. So thief of dark project
[2:09:48] comes on the heels of this. This is Tom
[2:09:49] Leonard. He's actually the guy who as
[2:09:51] far as anyone can remember that I've
[2:09:53] been able to, you know, that I've been
[2:09:54] able to get the solid story about. He's
[2:09:56] the guy who actually comes up with the
[2:09:58] idea of sort of the entity component
[2:10:00] model switch. And I didn't really call
[2:10:02] again too much stuff getting cut that
[2:10:03] we're going into now. So, you know, I
[2:10:05] guess six of one half dozen the other.
[2:10:06] But the idea of saying, okay, instead of
[2:10:09] entity.get hit points, we're going to
[2:10:11] say hit points.get entity. This is a big
[2:10:14] like that's a big switch if you never
[2:10:15] thought about it before, right? He's the
[2:10:18] one that like Mock says I think it was
[2:10:20] Tom who came up with that. And the
[2:10:21] reason is so that the types line up.
[2:10:23] It's like now instead of having like
[2:10:25] either tons of functions like get a hit
[2:10:27] points like thing, get a this that are
[2:10:29] on you know an entity which would suck.
[2:10:32] Now, we just ask the actual thing, the
[2:10:34] hit point system, and it's only going to
[2:10:35] return one type, which is like a hit
[2:10:36] points type to us, right?
[2:10:39] Um, and so anyway, this is what they're
[2:10:41] thinking about when they make the entity
[2:10:42] component system, and it comes from all
[2:10:44] of those experiences that they've had.
[2:10:46] They want to avoid fragmentation because
[2:10:48] they just had to make a thing that like
[2:10:49] restarts the game, right? Which was uh
[2:10:52] Flight Unlimited. They want arbitrary
[2:10:54] sized properties, right? Because they
[2:10:55] don't want to make those trade-offs
[2:10:56] between combat systems and fuel and
[2:10:58] whatever. They also had additional
[2:11:00] things which is like they wanted
[2:11:01] designers to be able to create types at
[2:11:03] runtime which the so they kind of want
[2:11:04] bags of properties that they can have
[2:11:06] designers create and they want designers
[2:11:08] to be able to do things like create
[2:11:09] domain mile um uh domain model
[2:11:12] hierarchies in the editor because
[2:11:14] they're thinking in terms of the domain
[2:11:16] model and it's just not implemented that
[2:11:17] way. Right? So they they do those
[2:11:18] things.
[2:11:19] >> And then finally the how fast is the
[2:11:21] fastest case thing. Uh that was from
[2:11:23] Doug Church. He was like, "Okay, if
[2:11:24] we're doing all this pie in the sky
[2:11:26] stuff, we have to figure out some way
[2:11:27] that it's still going to be as fast for
[2:11:29] like physics compute and stuff as what
[2:11:31] we used to do." And so what he did there
[2:11:33] was he was basically forcing them to go,
[2:11:34] we have to consider some way that this
[2:11:35] is all going to work. That was the
[2:11:36] system boundary drawings part. So that's
[2:11:38] the really fast part of this. And by the
[2:11:40] way, this is what it looks like inside
[2:11:42] the dark uh object system if you want to
[2:11:44] create a property type, right? It's like
[2:11:46] I said, it's still oop looking, right?
[2:11:48] Like like you could pass this by an oop
[2:11:50] person and they would be fine with it, I
[2:11:51] think. So, it's like again, not not oop,
[2:11:54] it's just not that uh hierarchy thing,
[2:11:56] right? Yeah. So, so there you go. I
[2:11:58] think that's everything.
[2:12:06] All right, let's see what else I've got.
[2:12:09] Um,
[2:12:12] yeah. So I guess um
[2:12:15] one interesting thing about what you
[2:12:17] were saying is that what it has to do
[2:12:19] with like the the object-oriented the
[2:12:22] original object-oriented work came from
[2:12:24] these like distributed systems and
[2:12:25] everything and I know you've talked a
[2:12:27] lot about in the past like Conway's law
[2:12:29] and how like introducing these
[2:12:31] boundaries
[2:12:33] or it's not introducing these boundaries
[2:12:35] it's the fact that when these boundaries
[2:12:37] arise they cause friction or difficulty
[2:12:39] and I guess um would you characterize
[2:12:42] this object-oriented thing is like
[2:12:44] creating those boundaries unnecessarily.
[2:12:45] So they didn't arise from the problem
[2:12:47] and so they're causing they're causing
[2:12:49] difficulty in that way.
[2:12:50] >> Um I would sort of say that I guess the
[2:12:54] only the only like caveat I can think of
[2:12:57] there is I think that the part where you
[2:13:00] said the problem ar like the problem
[2:13:03] doesn't arise from it or whatever or the
[2:13:04] or the you know it doesn't arise from
[2:13:06] the problem I think is how you phrase
[2:13:07] it. I think a person who thinks in terms
[2:13:10] of object-oriented programming and is an
[2:13:12] afficionado of that would claim that it
[2:13:15] is arising from the problem because the
[2:13:16] domain model looks like this right and
[2:13:19] so I don't agree with that but I don't
[2:13:22] know what they would agree with right
[2:13:24] and so from my perspective I agree with
[2:13:26] you these are things that just because
[2:13:28] as a human you're going I like to
[2:13:31] categorize things into groupings because
[2:13:33] that's something that we do right
[2:13:34] linguistically
[2:13:36] it's all quantum physics at the end or
[2:13:38] something, right, bro? So, it's like
[2:13:40] these are arbitrary categories that
[2:13:41] we're drawing. There's no reason to
[2:13:43] think, you know, just like I don't think
[2:13:45] the laws of the universe think of you as
[2:13:48] Ryan Flurry in a computational sense,
[2:13:51] but I think of you that way,
[2:13:53] >> right?
[2:13:53] >> It might not make sense for you to have
[2:13:56] the computational version of Ryan Flurry
[2:13:58] be about Ryan Flurry instead of just a
[2:14:00] collection of things that produces to
[2:14:02] the end user the effect of Ryan Flurry.
[2:14:04] Right? to me anyway that's sort of the
[2:14:07] difference there right it's like I don't
[2:14:08] see that the model inside the computer
[2:14:10] may have very little to do with the
[2:14:12] model experienced by the user which
[2:14:14] again is in direct conflict with like
[2:14:16] what Alan K wanted to do he wants and
[2:14:20] again you have to remember the mindset
[2:14:21] he also comes he wants to do education
[2:14:23] he wants to teach people about computing
[2:14:25] he wants it to he wants it to feel like
[2:14:28] you're programming in the same way that
[2:14:29] you see the real world and in some ways
[2:14:32] I think if we could just get to the
[2:14:33] point where and maybe he does think
[2:14:35] about this now. I'm not sure. Just get
[2:14:37] the point where he says thinks, "Oh,
[2:14:39] well that's just that's just when you
[2:14:40] use an application. That's what it feels
[2:14:42] like. It's not what it is under the
[2:14:43] hood." Then I think I'd be right there
[2:14:45] with him. Right.
[2:14:46] >> So,
[2:14:47] >> interesting.
[2:14:49] >> Um, all right. I'll check my list and
[2:14:51] then
[2:14:52] >> maybe if anyone in the audience has
[2:14:55] questions, then I will ask. But I'll
[2:14:57] check my list first since I'm up here
[2:14:59] talking about it.
[2:15:01] Um, okay. I had two pages. Uh,
[2:15:06] I did that one.
[2:15:12] Oh, yeah. I guess another thing. So, I
[2:15:14] guess I some of these are like not
[2:15:16] exactly questions, but they're like I
[2:15:18] formed a mental model given your talk
[2:15:20] and I want to run it by you and see if
[2:15:22] it makes sense. So one of the things
[2:15:25] another thing that I guess is implied by
[2:15:28] uh introducing these boundaries between
[2:15:30] parts of your program when when you
[2:15:33] could have not done that in the in the
[2:15:35] architecture but you did for one reason
[2:15:37] or another. Um the interesting thing is
[2:15:41] that you were talking about sketch is it
[2:15:43] sketchpad? Yeah sketchpad. it you have
[2:15:46] some layer which is like quoteunquote
[2:15:49] omnisient like it knows it it has full
[2:15:51] context of what's actually happening and
[2:15:53] in my mental model I'm like that's
[2:15:54] similar to when like an actual like
[2:15:57] civil engineer or something is like
[2:15:58] going and building a bridge like they
[2:16:00] they're not like how do I build a bridge
[2:16:02] without knowing what the landscape looks
[2:16:03] like kind of thing. So it's like um in
[2:16:08] that in that so a lot of the design
[2:16:09] decisions in C++ or in in all of the
[2:16:13] other paths that you that you iterated
[2:16:15] it seems like they're about like
[2:16:16] removing context or trying to find the
[2:16:18] minimal set of context but I assume like
[2:16:22] that doesn't seem help I haven't found
[2:16:23] that to be helpful
[2:16:25] because of you what you have taught
[2:16:28] basically but but I'm but I'm curious
[2:16:31] >> I kind of feel like you're on your own
[2:16:33] orbit now and you totally know exactly
[2:16:35] what it is, right? I mean, like, yeah,
[2:16:37] >> honestly, you're one of the best system
[2:16:39] architects I've ever seen. Full full
[2:16:40] disclosure, right, folks at home.
[2:16:42] Seriously, like it's insane. So, you
[2:16:44] don't need me to tell you what to do.
[2:16:46] >> All right. Well, thanks. I I appreciate
[2:16:48] that, but um uh so I guess uh you know,
[2:16:54] I think that's probably it. I'm having
[2:16:56] to turn through these two pages here. Uh
[2:16:59] but
[2:17:00] >> well to answer that question though like
[2:17:02] about the like removing that context,
[2:17:04] >> right? I do think like that's part of
[2:17:07] why it's frustrating to maybe look at
[2:17:10] the history a little bit. Yeah. Because
[2:17:11] what it looks like to me from like the
[2:17:14] the bird's eye view is like instead of
[2:17:17] asking how do we achieve code reuse and
[2:17:20] modularity while preserving our ability
[2:17:23] to solve the hardest problems,
[2:17:25] >> it looked more like it was like let's
[2:17:27] just redefine the problem to be simpler
[2:17:29] and solve that. Yeah.
[2:17:31] >> And to me that that was one of the big
[2:17:33] things about the sketchpad thing as well
[2:17:34] where it's like okay you had working
[2:17:37] examples of this that are pretty well
[2:17:38] documented. I mean if I can go figure
[2:17:40] out most of it now looking back at the
[2:17:43] than at the time when you could have
[2:17:44] actually talked to Ivan Sutherland fresh
[2:17:45] off of the implementation where he
[2:17:46] remembered it all right.
[2:17:48] >> Um and so it does really feel like I
[2:17:50] feel like there's a failure to engage
[2:17:52] with the hardest problems. And I think
[2:17:54] one of my takeaways from it, which you
[2:17:56] know, from reading the history, which is
[2:17:59] not it it didn't really change my mind
[2:18:01] about this, it just reinforced kind of
[2:18:02] like my feeling about it, which is I
[2:18:04] think when you're designing new things,
[2:18:06] you should focus on the hardest stuff.
[2:18:08] >> You should say what solves the hardest
[2:18:10] problems because we can always then take
[2:18:12] that and scale it down and remove things
[2:18:14] from it or dumb it down for an for
[2:18:17] people to use in cases where that aren't
[2:18:19] as hard. But it's almost impossible to
[2:18:22] take something that only solves simple
[2:18:23] problems and scale it up into something
[2:18:24] that solves hard ones. And so that was
[2:18:26] that's really the thing. And I don't I
[2:18:28] don't blame anyone in this uh that I
[2:18:31] covered here for that at all because the
[2:18:34] conditions they were working under are
[2:18:35] awful, right? I mean, they have no they
[2:18:37] have none of the benefits we have today.
[2:18:39] They were working with computer systems
[2:18:40] they barely got time on half the time.
[2:18:42] It was hard to debug, all that stuff.
[2:18:43] And they're having to invent all this
[2:18:45] stuff themselves, right? They have
[2:18:46] nothing to fall back on. So it's
[2:18:48] nobody's fault. But going forward, it's
[2:18:50] like when we have good tools, let's
[2:18:51] attack the hardest problems and that
[2:18:53] will be where we get our really good
[2:18:54] architectures. That's my feeling about
[2:18:56] it. Anyway,
[2:18:56] >> do you blame uh Y Combinator at all for
[2:18:59] like the internet or
[2:19:01] >> I'm about to blame them when I see what
[2:19:02] they post about this talk and somehow
[2:19:04] managed to miss all of the good
[2:19:06] arguments you might have about it and
[2:19:07] argue about something else like whether
[2:19:09] or not that was the right use of
[2:19:10] discriminated union, which 100% will
[2:19:12] happen, right? And you're just like,
[2:19:13] "Guys, who cares?" Like that does not
[2:19:16] matter right now, right? But okay.
[2:19:18] >> Yeah. Because I think like actually
[2:19:19] programming that tends to be one of the
[2:19:21] harder problems is know like well I
[2:19:23] don't know you've said it you've said it
[2:19:24] a hundred times already in the talk but
[2:19:26] where you draw those boundaries because
[2:19:28] it's not that modularity stops being
[2:19:29] useful it's that it it's a wall you're
[2:19:32] introducing that makes something more
[2:19:34] difficult and so if you put that right
[2:19:35] into the middle of your of the hard
[2:19:37] problem like you say yeah
[2:19:39] >> and I think the that is the fundamental
[2:19:41] struggle it's why architecture is so
[2:19:43] hard and it's also why architecture is
[2:19:45] potentially difficult to reuse
[2:19:47] architecture not like reuse inside an
[2:19:49] architecture. And it's because when you
[2:19:52] draw those encapsulation boundaries
[2:19:54] properly for a particular problem, you
[2:19:56] save orders of magnitude of work when
[2:19:59] you do it properly. And the where you
[2:20:01] draw them could very well be different
[2:20:04] for different types of things you're
[2:20:05] trying to solve. And that makes it hard
[2:20:07] to say, okay, here's an architecture
[2:20:08] that just works across things. or one of
[2:20:10] the reasons the compile time hierarchy
[2:20:11] thing I think is a bad idea is not just
[2:20:13] because I don't think it's very useful
[2:20:15] in general but it's also because it's
[2:20:17] procrustian it's like this
[2:20:18] oneizefits-all approach that I don't
[2:20:20] think really even fits that many
[2:20:22] problems but it certainly doesn't fit uh
[2:20:24] all problems right and so teaching
[2:20:26] architecture I think it would be better
[2:20:28] to focus on more flexible thinking and
[2:20:31] thinking about drawing the encapsulation
[2:20:33] boundaries with intent not with a a
[2:20:35] fixed model in mind and if that intent
[2:20:38] leads you to a very unus usual placement
[2:20:40] of the boundaries. As long as you can
[2:20:42] prove that it's actually getting you
[2:20:44] that leverage and not introducing cuts
[2:20:46] in places where it makes programming
[2:20:48] difficult, then then you should do that.
[2:20:50] You should follow that sort of weird
[2:20:52] structure because that is probably
[2:20:54] right.
[2:20:55] >> Yeah, that makes sense. Um, okay. Well,
[2:20:59] I've I think I've exhausted all the all
[2:21:01] the questions or discussion topics. Um
[2:21:04] or they would be rehashing things that
[2:21:06] you like I wrote them down and then you
[2:21:08] covered them in the talk and I was like
[2:21:09] okay um so I'll ask the audience does
[2:21:12] anyone have
[2:21:13] >> should we also should we just cut now?
[2:21:15] Is that good time to stop because the
[2:21:16] >> Well, we we can do one we have maybe
[2:21:18] five minutes.
[2:21:19] >> Okay. Okay. Shoot. Sorry. Sorry
[2:21:21] everyone. Um okay. Uh Rafael, do you
[2:21:24] have a do you have a question? You can
[2:21:26] just speak out.
[2:21:26] >> Yes. like um if we had the solution in
[2:21:29] the 60s and we saw the power of like
[2:21:32] sketchpad and like why was let's call it
[2:21:35] dark oop still able to gain foothold and
[2:21:39] catch on and suppress the good solution
[2:21:41] was it because was it a successional
[2:21:43] knowledge transfer problem or was it
[2:21:45] just because dark oop is such a catnet
[2:21:47] for programmers because lots of
[2:21:49] interesting problem how do I represent
[2:21:51] that or like or or was it something else
[2:21:53] like why does it catch on
[2:21:54] >> I mean it's very speculative to try and
[2:21:56] Yes, something like that. Obviously, uh
[2:21:58] I think you touched on some of the
[2:22:00] answer there, which is that like I do
[2:22:02] think people want to divide things into
[2:22:04] hierarchical categories kind of
[2:22:05] naturally. I mean, we did that with the
[2:22:07] natural world when we were trying to do
[2:22:08] biological classifications long before
[2:22:10] we had really any basis to do so like
[2:22:12] before we knew about, you know, DNA or
[2:22:14] anything like that or or how, you know,
[2:22:17] uh those things might have happened. So,
[2:22:18] I think it's a natural thing for people
[2:22:19] who want to do to make those
[2:22:20] classifications. So, there's some of
[2:22:21] that and thinking that there's this easy
[2:22:25] sort of model that just goes from what
[2:22:27] you see, it's like wizzywig
[2:22:28] architecture, like what I see in the
[2:22:29] real world is just what the code looks
[2:22:30] like and we're done, right? Um, so think
[2:22:33] there's a little bit of that, but I
[2:22:35] think the real story is just that
[2:22:37] history is very messy and in order for
[2:22:40] something to gain traction, somebody has
[2:22:42] to like champion it. Someone has to do
[2:22:44] the work of implementing it into a
[2:22:45] system and doing a good job of that,
[2:22:47] right? One of the reasons we got the
[2:22:50] sort of compile time hierarchy thing is
[2:22:52] because that's what stretrip kind of
[2:22:54] took away from simula. It's what he
[2:22:55] implemented first into a language that
[2:22:57] became very popular. And he wasn't
[2:23:01] trying to do anything nefarious, right?
[2:23:02] He wasn't trying to do anything dark.
[2:23:03] He's just like, I like this typeing
[2:23:05] thing. I use simul was kind of cool. He
[2:23:08] did the work, right? Um I mean, you
[2:23:11] could say that about uh things that we
[2:23:12] see happening today as well. It's like,
[2:23:14] you know, in order for something like,
[2:23:16] you know, Rust or something to gain
[2:23:17] popular, somebody has to build Rust
[2:23:19] first. Somebody has an idea of what it's
[2:23:20] going to be. Is that idea good or bad,
[2:23:23] who knows? But in order for it to even
[2:23:25] get judged in the marketplace, somebody
[2:23:26] has to do that. And the bottom line is
[2:23:28] nobody who looked at Sketchpad was
[2:23:30] thinking in terms of architecture other
[2:23:32] than what I said, which is like the like
[2:23:33] virtual dispatch basically. And you know
[2:23:35] I didn't go into the talk but Allan Kay
[2:23:38] was he was predisposed also to think
[2:23:40] about that virtual dispatch as being
[2:23:42] very important because the other
[2:23:44] references that I didn't mention uh but
[2:23:46] they were in that quote I said we're not
[2:23:48] going to cover them. They're like the
[2:23:49] Burrows 5000 series computers. Uh, and
[2:23:52] the there's this Air Force this guy who
[2:23:55] wrote a file system thing where you put
[2:23:57] the like way to way that you use the
[2:24:00] files in the file system were sub
[2:24:02] routines that were stored in front of
[2:24:03] the files in the file system. So it's
[2:24:05] kind of like a virtual like dispatch
[2:24:07] thing.
[2:24:08] The Burough's 5000 system also had this
[2:24:11] kind of virtual dispatch where there
[2:24:12] were like tables and things. And so for
[2:24:14] Alan Kay, who we didn't really cover in
[2:24:16] here, there the other three hours of
[2:24:18] slides, they're all there, right? But
[2:24:20] what he actually was seeing was he was
[2:24:22] seeing commonality there. He was like,
[2:24:24] "Oh, the Burrows 5000, that Air Force
[2:24:27] thing that I thought was cool. Uh,
[2:24:29] Simula and Sketchpad are all doing this
[2:24:32] dispatch table thing, and they're all
[2:24:34] like making classes with these
[2:24:35] dispatches on them." And then he's
[2:24:37] thinking molecular biology and this
[2:24:38] messaging like you're going to respond
[2:24:40] to these messages. That's what these
[2:24:41] dispatches are. or they're like how
[2:24:42] you're responding to different messages
[2:24:44] and he just goes down that path because
[2:24:46] he's he's thinking that that's the core
[2:24:48] thing, right? Because he's presupposed
[2:24:50] to see it because he's encountered this
[2:24:51] idea multiple times and so he's
[2:24:53] predisposed I think to think that that's
[2:24:54] where the power of Sketchpad comes from
[2:24:56] because like let's face it, would we
[2:24:59] have recognized that power at all if we
[2:25:01] hadn't had all of this experience? And
[2:25:03] like you know I it I just randomly kind
[2:25:06] of stumbled upon this like oh wow wait
[2:25:07] okay like that's really kind of
[2:25:09] interesting sort if I had never seen an
[2:25:10] ND component system before would I ever
[2:25:12] even have thought of that? Probably not.
[2:25:14] >> So I think it's just it's a really hard
[2:25:15] it's a really big ask. It's a tremendous
[2:25:17] ask to ask someone who's like inventing
[2:25:19] C++ or inventing simula to somehow get
[2:25:22] all of that. It's it's just not it's
[2:25:24] just not plausible, you know. It's not
[2:25:26] plausible. It's a hindsight thing.
[2:25:28] >> Yeah,
[2:25:28] >> I think. Sure.
[2:25:30] Um uh we have a question right here.
[2:25:33] >> So it seems to me that the pattern is
[2:25:35] always the same. Like you kind of come
[2:25:37] from school. It was my pattern too and
[2:25:38] it seems that it's yours, right? You
[2:25:39] learn a certain way and in school
[2:25:41] everything is kind of tied to business
[2:25:43] stuff, right? So it's it's very easy to
[2:25:44] think about you have a client with an
[2:25:46] invoice with items, right? And usually
[2:25:48] it's not even it doesn't go that deep
[2:25:50] into very high hierarchies, but we kind
[2:25:53] of just learn that pattern and then we
[2:25:55] just start using it. And you have a
[2:25:57] hammer that is a melee weapon that is a
[2:25:58] weapon and whatever. And then we have to
[2:26:01] have the luck of finding somebody along
[2:26:03] on our path that kind of snaps us out of
[2:26:05] us and shows us a different path. But
[2:26:07] also these people are kind of
[2:26:10] disappearing from the industry. So my
[2:26:12] question is like how do we fix this
[2:26:14] problem? How can we improve this?
[2:26:16] Because it kind of feels like you're
[2:26:18] trying to get smokers from stop smoking
[2:26:21] long after they're smoking. You know
[2:26:23] what I mean? So you're
[2:26:24] >> Well, I guess I would say you're at the
[2:26:26] right conference. I I mean that's like
[2:26:29] right I mean I don't know you start
[2:26:31] doing stuff like this and you try to go
[2:26:33] through the history and show how it
[2:26:34] happened and stuff like that and that's
[2:26:36] that's it you know I mean that's the
[2:26:38] best you can do is put these ideas out
[2:26:39] there uh suffer the hacker news thread
[2:26:42] that you will then have to uh endure
[2:26:44] right or whatever else has to happen and
[2:26:46] then you hope that maybe some of those
[2:26:48] ideas get picked up and people think
[2:26:50] about it more critically I think we're
[2:26:51] out of time correct
[2:26:53] >> there is coffee we're going on break now
[2:26:55] we'll be back at 20 or dense.
[2:26:59] >> All right. Uh well, hope I I will be in
[2:27:02] the audience uh anxiously watching this
[2:27:04] talk. This is this is from Tearown,
[2:27:06] right?
[2:27:06] >> Uh I think so. Yep.
[2:27:08] >> Okay. I'm excited to see this one. I'm
[2:27:09] really looking forward to it, Dennis.
[2:27:11] >> All right. So, we'll be back here at 20.
[2:27:13] >> Thank you, Ryan.
[2:27:14] >> Yep.