|
|
|
|
|
by justinpombrio
2555 days ago
|
|
The first set of points: > Classes make functions visible while keeping data implied. Data structures make data visible while keeping functions implied.
> Classes make it easy to add types but hard to add functions. Data structures make it easy to add functions but hard to add types. is known as the Expression Problem https://en.wikipedia.org/wiki/Expression_problem. The last point: > Data Structures expose callers to recompilation and redeployment. Classes isolate callers from recompilation and redeployment. is only somewhat true. I suspect it would be more accurate to say that it's a matter of indirection: static dispatch isolates callers from recompilation; static dispatch exposes callers to recompilation; calling a function pointer isolates callers from recompilation; calling a function directly exposes callers to recompilation. (All of this in statically typed languages.) Though this isn't my area of expertise. Perhaps someone else knows more? [Edit: sounds like these "expose" cases often don't cause recompilation either.] |
|
... most projects (maybe all?) I've worked on in 20+ years deployed a full set of new bits upon release, rather than trying to differentiate at the level of which source code files were and were not touched.
So this strikes me as a carryover from many years ago when working on large C++ projects with slow compile times was even more painful than it is today.
Any counterpoints?