flowtype / ocaml-dtoa
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 90 units with 1,416 lines of code in units (81.7% of code).
    • 0 very long units (0 lines of code)
    • 4 long units (258 lines of code)
    • 24 medium size units (669 lines of code)
    • 16 small units (256 lines of code)
    • 46 very small units (233 lines of code)
0% | 18% | 47% | 18% | 16%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
c0% | 18% | 47% | 18% | 15%
js0% | 0% | 0% | 0% | 100%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src0% | 18% | 47% | 18% | 15%
js0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
88 9 9
58 12 3
56 14 7
static bool digit_gen()
in src/fast_dtoa.c
56 7 6
void bignum_square()
in src/bignum.c
43 7 1
39 6 2
static int shortest_dtoa()
in src/dtoa_stubs.c
38 12 4
35 6 2
static bool grisu3()
in src/fast_dtoa.c
35 3 5
34 9 3
30 10 3
29 6 6
28 5 9
26 6 3
static void BignumToFixed()
in src/bignum_dtoa.c
25 4 6
25 5 2
25 3 2
25 5 2
static bool round_weed()
in src/fast_dtoa.c
25 10 7
static int i_to_str()
in src/dtoa_stubs.c
25 5 2