Phil Eaton

19%
Flag icon
The conventional wisdom in programming is that classes should be small, not deep. Students are often taught that the most important thing in class design is to break up larger classes into smaller ones. The same advice is often given about methods: “Any method longer than N lines should be divided into multiple methods” (N can be as low as 10). This approach results in large numbers of shallow classes and methods, which add to overall system complexity. The extreme of the “classes should be small” approach is a syndrome I call classitis, which stems from the mistaken view that “classes are ...more
Phil Eaton
Just talking about function size vs. too many functions doesn't get into the dimension of mutability vs immutability. A bunch of immutable helper functions is _ok_ but a bunch of helper functions with aide effects is a nightmare.
A Philosophy of Software Design
Rate this book
Clear rating