[clang] 3b37924 - [clang-format] A Minor change to clang-format-diff.py
via cfe-commits
cfe-commits at lists.llvm.org
Mon Apr 13 07:08:48 PDT 2020
Author: mydeveloperday
Date: 2020-04-13T15:08:07+01:00
New Revision: 3b379246c365721425d7e29772c08d8373b4a606
URL: https://github.com/llvm/llvm-project/commit/3b379246c365721425d7e29772c08d8373b4a606
DIFF: https://github.com/llvm/llvm-project/commit/3b379246c365721425d7e29772c08d8373b4a606.diff
LOG: [clang-format] A Minor change to clang-format-diff.py
Summary: Testing for None should use the 'is' operator.
Reviewed By: MyDeveloperDay
Patch By: eagleoflqj
Tags: #clang-format
Differential Revision: https://reviews.llvm.org/D77974
Added:
Modified:
clang/tools/clang-format/clang-format-diff.py
Removed:
################################################################################
diff --git a/clang/tools/clang-format/clang-format-
diff .py b/clang/tools/clang-format/clang-format-
diff .py
index 122db49ff73c..24c6f4ae456c 100755
--- a/clang/tools/clang-format/clang-format-
diff .py
+++ b/clang/tools/clang-format/clang-format-
diff .py
@@ -65,7 +65,7 @@ def main():
match = re.search(r'^\+\+\+\ (.*?/){%s}(\S*)' % args.p, line)
if match:
filename = match.group(2)
- if filename == None:
+ if filename is None:
continue
if args.regex is not None:
More information about the cfe-commits
mailing list