novifinancial / serde-reflection
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 929 units with 9,828 lines of code in units (67.2% of code).
    • 0 very complex units (0 lines of code)
    • 1 complex units (257 lines of code)
    • 5 medium complex units (561 lines of code)
    • 47 simple units (1,942 lines of code)
    • 876 very simple units (7,068 lines of code)
0% | 2% | 5% | 19% | 71%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
rs0% | 3% | 6% | 22% | 67%
py0% | 0% | 30% | 4% | 65%
java0% | 0% | 0% | 25% | 74%
cs0% | 0% | 0% | 17% | 82%
dart0% | 0% | 0% | 19% | 80%
hpp0% | 0% | 0% | 7% | 92%
go0% | 0% | 0% | 5% | 94%
ts0% | 0% | 0% | 6% | 93%
swift0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
serde-generate/src0% | 5% | 8% | 25% | 60%
serde-generate/runtime/python0% | 0% | 30% | 4% | 65%
serde-reflection/src0% | 0% | 0% | 16% | 83%
serde-generate/runtime/java0% | 0% | 0% | 25% | 74%
serde-generate/runtime/csharp0% | 0% | 0% | 17% | 82%
serde-generate/runtime/dart0% | 0% | 0% | 19% | 80%
serde-generate/runtime/cpp0% | 0% | 0% | 7% | 92%
serde-generate/runtime/golang0% | 0% | 0% | 5% | 94%
serde-generate/runtime/typescript0% | 0% | 0% | 6% | 93%
serde-name/src0% | 0% | 0% | 0% | 100%
serde-generate/runtime/swift0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
257 45 5
55 21 3
156 21 5
73 20 2
187 18 5
90 12 5
25 10 1
97 10 5
36 10 2
79 10 3
110 10 3
50 9 4
22 9 1
35 9 1
79 9 5
11 8 2
19 8 1
23 8 1
45 7 1
49 7 2
40 7 2
21 7 1
9 7 2
10 7 0
16 7 1
103 7 3
85 7 3
44 7 3
56 7 3
72 6 2
19 6 1
18 6 0
24 6 3
18 6 0
18 6 0
14 6 1
23 6 3
9 6 0
13 6 1
21 6 0
23 6 0
10 6 1
25 6 2
8 6 1
42 6 4
78 6 3
100 6 3
25 6 2
104 6 3
61 6 3