News for hackers. Stuff that matters.
Re:Can you use a class in C? by bobboies on Sunday August 13, 2023 @03:16PM (#37113247)
Also see:

Effective C++ (by Scott Meyers) Item 23:

“Prefer non-member non-friend functions to member functions. Doing so increases encapsulation, packaging flexibility, and functional extensibility.”

The text has a lot more detail but that’s a brief summary. Folks just need to read the literature then this sort of knowledge would be in common use.

One downside of language evolution is a lot of people focusing on new language features, etc, but then some of this older, important knowledge gets skipped over.

There are no comments on this comment yet.