-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add enhancement proposal for unused code which appears
after removing unused code.
- Loading branch information
Showing
1 changed file
with
18 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# DEP 3 - Removal of unused code might create new unused code | ||
**Status**: Proposed | ||
**Type**: Feature | ||
**Created**: 2024-04-16 | ||
|
||
## Problem statement | ||
Additional unused code could appear after removal of unused code, since | ||
some code might have been used by code, which was not used. | ||
|
||
## Considered solutions | ||
These solutions are possible: | ||
- apply deadcode multiple times till the output does not change in two consequtive runs. | ||
- intelligently mark which code parts are unused and dont mark code as used, if it is used only by the code, which is unused. | ||
|
||
## Chosen soluton | ||
Intelligent code tracking should be implemented, to make this algorithm more efficient. | ||
Implementation details should still be considered: | ||
- Code usage tree might have to be constructed with actual links to usages, which might require a lot of memory. |