Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
46 lines (31 sloc) 1.57 KB
Root.Smell.Complexity Parent Index
Sibling aspects ClassSmell MethodSmell Naming

Complexity

Complexity of a code based on different complexity metrics.

Subaspects

Example

* McCabe's complexity
* Halstead complexity
* Elshof complexity
* Data complexity
etc...

Here is an example of complex code:
https://github.com/sympy/sympy/blob/master/sympy/solvers/solvers.py

Importance

Complex programs are difficult to read and maintain. Reducing a code's complexity improves its organization.

How to fix this

Implementing simple methods, avoiding too many branches, avoiding too much multilevel inheritance etc... can fix this.