summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKenix3 <kenixwhisperwind@gmail.com>2021-03-09 17:55:52 -0500
committerKenix3 <kenixwhisperwind@gmail.com>2021-03-10 22:28:06 -0500
commit375f99f2b43523efe69019c3db8bed15bb475984 (patch)
tree88019e34917f24db13749168eed4ae1af3cf6123
parent710c3d17b0051f17cffb49bb7bc5869a47309175 (diff)
Fixes matching and non-matching counts in progress.py
-rwxr-xr-xtools/progress.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/progress.py b/tools/progress.py
index 51c2ba358..8c78886d5 100755
--- a/tools/progress.py
+++ b/tools/progress.py
@@ -60,12 +60,17 @@ map_file = ReadAllLines('build/mm.map')
# Get list of Non-Matchings
all_files = GetFiles("src", ".c")
-non_matching_functions = GetFunctionsByPattern(NON_MATCHING_PATTERN, all_files) if not args.matching else []
+non_matching_functions = GetFunctionsByPattern(NON_MATCHING_PATTERN, all_files)
# Get list of functions not attempted.
not_attempted_functions = GetFunctionsByPattern(NOT_ATTEMPTED_PATTERN, all_files)
not_attempted_functions = list(set(not_attempted_functions).difference(non_matching_functions))
+# If we are looking for a count that includes non-matchings, then we want to set non matching functions list to empty.
+# We want to do this after not attempted functions list generation so we can remove all non matchings.
+if not args.matching:
+ non_matching_functions = []
+
# Initialize all the code values
src = 0
src_code = 0