dart-lang / code_builder
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 15% duplication:
    • 834 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 131 duplicated lines
  • 7 duplicates
system15% (131 lines)
Duplication per Extension
dart17% (131 lines)
Duplication per Component (primary)
lib/src21% (131 lines)
lib0% (0 lines)
lib/src/mixins0% (0 lines)
example0% (0 lines)
tool/src0% (0 lines)
ROOT0% (0 lines)
Longest Duplicates
The list of 7 longest duplicates.
See data for all 7 duplicates...
Size#FoldersFilesLinesCode
26 x 2 lib/src
lib/src
emitter.dart
emitter.dart
215:248 (5%)
512:545 (5%)
view
12 x 2 lib/src
lib/src
emitter.dart
visitors.dart
9:20 (2%)
9:20 (36%)
view
11 x 2 lib/src
lib/src
emitter.dart
emitter.dart
141:156 (2%)
299:314 (2%)
view
9 x 2 lib/src
lib/src
emitter.dart
emitter.dart
176:186 (1%)
298:308 (1%)
view
8 x 2 lib/src
lib/src
emitter.dart
emitter.dart
141:150 (1%)
177:186 (1%)
view
6 x 2 lib/src
lib/src
emitter.dart
emitter.dart
195:201 (1%)
485:491 (1%)
view
6 x 2 lib/src
lib/src
emitter.dart
emitter.dart
130:136 (1%)
170:176 (1%)
view