“Value Semantics: It ain't about the syntax!, Part II"
summary
Argument: value semantics hinge on salient attributes and an Essential Property of Value: if two objects have the same value, performing the same mutating operation preserves that equality. Concrete conclusions: ordered-set bit flags, rational canonicalization versus overflow, and graph isomorphism make equality expensive or meaningless; regular-expression equality is PSPACE-hard so omit operator== or provide a warned utility; priority-queue equality requires identical linear heap order (constructive "water-and-rock" proof shows necessity). Prefer explicit named utilities when equality is costly.
AI-written summary · about
chapters (6)
- 0:00Introduction and recap
- 6:44Designing value types
- 22:19Salient attributes and equality
- 25:09Regular expressions as values
- 41:16Priority queues and value semantics
- 1:03:01Conclusion and key takeaways
related talks
59mThe Most Valuable Values
01h 42mValue Oriented Programming Part V - Return of the Values
17mContextual Equality Saturation
11mThe Value of Objects -
30megg: Fast and Extensible Equality Saturation
01h 02mObjects vs Values: Value Oriented Programming in an Object Oriented World
58mOO Considered Harmful
01h 00m“Enhanced Support for Value Semantics in C++17”
