Cpp Coding Standards/DESIGN/CyclDep

From Apache OpenOffice Wiki
Jump to: navigation, search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Avoid unnecessary dependencies (because they increase coupling, and thus (re)compile time). Cyclic dependencies are even worse: they glue two (or more) seemingly unrelated units together, into something larger, whose parts cannot be used (or tested, or deployed) in isolation.

Use the Dependency Inversion Principle to break cyclic dependencies.

Personal tools