Author: Mircea Trofin Date: 2020-12-15T08:48:37-08:00 New Revision: 380e1d918cb4581fae0277ff547d75334f3e7ddd
URL: https://github.com/llvm/llvm-project/commit/380e1d918cb4581fae0277ff547d75334f3e7ddd DIFF: https://github.com/llvm/llvm-project/commit/380e1d918cb4581fae0277ff547d75334f3e7ddd.diff LOG: [utils] The func_dict for a prefix may just be empty Follow up from D92965 - since we try to find failed prefixes after each RUN line, it's possible the whole list of functions for a prefix be non-existent, which is fine - this happens when none of the RUN lines seen so far used the prefix. Added: Modified: llvm/utils/UpdateTestChecks/common.py Removed: ################################################################################ diff --git a/llvm/utils/UpdateTestChecks/common.py b/llvm/utils/UpdateTestChecks/common.py index 8cd90deefdb9..21878e81b89f 100644 --- a/llvm/utils/UpdateTestChecks/common.py +++ b/llvm/utils/UpdateTestChecks/common.py @@ -261,10 +261,10 @@ def __str__(self): def get_failed_prefixes(func_dict): # This returns the list of those prefixes that failed to match any function, # because there were conflicting bodies produced by diff erent RUN lines, in - # all instances of the prefix. Effectivelly, this prefix is unused and should + # all instances of the prefix. Effectively, this prefix is unused and should # be removed. for prefix in func_dict: - if (not [fct for fct in func_dict[prefix] + if func_dict[prefix] and (not [fct for fct in func_dict[prefix] if func_dict[prefix][fct] is not None]): yield prefix _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits