From e19b51bc533194c7447e47e15d75441450e93408 Mon Sep 17 00:00:00 2001 From: Pengyu Lv Date: Tue, 14 Feb 2023 10:29:53 +0800 Subject: [PATCH] Improve readability Signed-off-by: Pengyu Lv --- scripts/code_style.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/code_style.py b/scripts/code_style.py index 65c9cccfb..eaf1f6b88 100755 --- a/scripts/code_style.py +++ b/scripts/code_style.py @@ -191,12 +191,12 @@ def main() -> int: args = parser.parse_args() - all_src_files = get_src_files() - src_files = args.operands if args.operands else all_src_files + covered = frozenset(get_src_files()) + src_files = args.operands if args.operands else covered if args.subset: # We are to check a subset of the default list - src_files = [f for f in args.operands if f in all_src_files] - skip_src_files = [f for f in args.operands if f not in src_files] + src_files = [f for f in args.operands if f in covered] + skip_src_files = [f for f in args.operands if f not in covered] if skip_src_files: print_skip(skip_src_files)