Overview
This video asks whether object-oriented programming was a failure, drawing on Casey Muratori’s 2025 talk “The Big OOPs” and the comments engineers left on it. It does not reject OOP as a whole. The criticism targets one habit: turning real-world categories into compile-time inheritance hierarchies and drawing encapsulation boundaries around them.
Key Points
- In 1998, Looking Glass Studios built Thief: The Dark Project on what the video calls the first entity component system (ECS) in a commercial game. Entities are just IDs, and data lives in arrays owned by systems such as physics, so the boundary surrounds systems, not objects.
- Many modern tools existed by the 1960s: Douglas Ross’s plex, the forerunner of the struct, with embedded function pointers; Ivan Sutherland’s Sketchpad, essentially ECS-like; and Tony Hoare’s 1966 paper proposing subclasses and type-safe discriminated unions. The 35 years in the title run from Sketchpad (1963) to Thief.
- Simula introduced class inheritance to reuse code, mixing implementation reuse and domain modeling into one feature. Bjarne Stroustrup, whose distributed-systems simulations matched classes to physical machines, put Simula’s classes into C as C with Classes, the forerunner of C++, but dropped the discriminated unions Simula had. They took decades to return in languages like Rust and TypeScript.
- Three takeaways: draw boundaries around processing such as authentication or payments rather than nouns, prefer composition over inheritance, and use discriminated unions. Classes and interfaces stay useful; hierarchies should be a last resort.
Chapters
- 0:00 Introduction
- 0:41 Chapter 1: The rebellion of 1998
- 6:47 Chapter 2: A journey to the origins
- 18:10 Chapter 3: A game of telephone
- 29:42 Chapter 4: Lessons for today
- 31:47 Three principles you can use tomorrow
概要
ケイシー・ムラトリ(Casey Muratori)が2025年に公開した講演「The Big OOPs」と、そこに寄せられたエンジニアたちのコメントをもとに、オブジェクト指向は失敗だったのかを問い直す動画です。OOPのすべてを否定する話ではありません。批判の対象は、現実世界の分類をそのままコンパイル時の継承階層に置き換え、そこにカプセル化の境界線を引くという習慣1点です。
ポイント
- 1998年、Looking Glass Studios は『Thief: The Dark Project』で、商用ゲームとして世界初とされるエンティティ・コンポーネント・システム(ECS)を採用しました。エンティティはただのIDで、データは物理などのシステムごとの配列に置かれます。境界線をオブジェクトではなくシステムの周りに引いた設計です。
- 現代の道具の多くは1960年代にすでに揃っていました。関数ポインターも埋め込める構造体の起源、ダグラス・ロスの「プレックス」。実質的にECSと同じ発想のアイバン・サザランドのSketchpad。そしてサブクラスと型安全な判別共用体を提案したトニー・ホーアの1966年の論文です。タイトルの35年は、Sketchpad(1963年)からThiefまでの年月を指します。
- Simulaはコードの再利用のためにクラス継承を生み、実装の再利用と現実の分類の表現という目的の違う2つを1つの機能に混ぜ込みました。クラスの境界と物理的なマシンの境界が一致する分散システムのシミュレーションを経験したビャーネ・ストラウストラップは、C言語にSimulaのクラスを載せた C with Classes(C++の前身)を作りましたが、Simulaにあった判別共用体は捨てました。この機能がRustやTypeScriptなどで戻ってくるまでには数十年かかっています。
- 明日から使える原則は3つです。境界線は名詞ではなく認証や決済といった処理のまとまりに引く、継承よりコンポジションを選ぶ、判別共用体を使う。クラスやインターフェースは今も便利な道具で、階層は最後の手段にします。