Use IO<File> as data source for memory editors #2011
CodeScene PR Check
Quality Gate Failed
Gates Failed
Enforce advisory code health rules
(2 files with Code Duplication, Complex Conditional)
Gates Passed
3 Quality Gates Passed
See analysis details in CodeScene
Reason for failure
| Enforce advisory code health rules | Violations | Code Health Impact | |
|---|---|---|---|
| file.cc | 1 advisory rule | 8.82 → 8.55 | Suppress |
| imgui_memory_editor.cpp | 1 advisory rule | 5.18 → 5.15 | Suppress |
Quality Gate Profile: Clean Code Collective
Install CodeScene MCP: safeguard and uplift AI-generated code. Catch issues early with our IDE extension and CLI tool.
Details
🚩 Declining Code Health (highest to lowest):
- Code Duplication file.cc
- Complex Conditional imgui_memory_editor.cpp: MemoryEditor::DrawContents
✅ Improving Code Health:
- Complex Method imgui_memory_editor.cpp: MemoryEditor::DrawContents
- Overall Code Complexity imgui_memory_editor.cpp
Annotations
Check warning on line 1 in src/support/file.cc
codescene-delta-analysis / CodeScene Code Health Review (main)
❌ Getting worse: Code Duplication
introduced similar code in: PCSX::SubFile::readAt,PCSX::SubFile::wSeek,PCSX::SubFile::writeAt. Avoid duplicated, aka copy-pasted, code inside the module. More duplication lowers the code health.
Check notice on line 369 in third_party/imgui_memory_editor/imgui_memory_editor.cpp
codescene-delta-analysis / CodeScene Code Health Review (main)
✅ Getting better: Complex Method
MemoryEditor::DrawContents decreases in cyclomatic complexity from 81 to 80, threshold = 9. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.
Check warning on line 298 in third_party/imgui_memory_editor/imgui_memory_editor.cpp
codescene-delta-analysis / CodeScene Code Health Review (main)
❌ Getting worse: Complex Conditional
MemoryEditor::DrawContents increases from 2 complex conditionals with 4 branches to 3 complex conditionals with 7 branches, threshold = 2. A complex conditional is an expression inside a branch (e.g. if, for, while) which consists of multiple, logical operators such as AND/OR. The more logical operators in an expression, the more severe the code smell.
Check notice on line 1 in third_party/imgui_memory_editor/imgui_memory_editor.cpp
codescene-delta-analysis / CodeScene Code Health Review (main)
✅ Getting better: Overall Code Complexity
The mean cyclomatic complexity decreases from 11.31 to 10.82, threshold = 4. This file has many conditional statements (e.g. if, for, while) across its implementation, leading to lower code health. Avoid adding more conditionals.