From aa189ed25fbd861b07eb5d5116dfd8e33e2b1991 Mon Sep 17 00:00:00 2001 From: Yannick Brehon Date: Tue, 3 Dec 2019 12:52:59 +0100 Subject: [PATCH] Fix compatibility with python3 of clang-include-fixer.py clang-include-fixer was recently updated to be python3-compatible. However, an exception handling clause was improperly using the deprecated `message` property of Exception classes, so the code was not yet entirely python3-compatible. Differential Revision: https://reviews.llvm.org/D70902 --- .../clang-include-fixer/tool/clang-include-fixer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clang-tools-extra/clang-include-fixer/tool/clang-include-fixer.py b/clang-tools-extra/clang-include-fixer/tool/clang-include-fixer.py index fcdd5a0b60ee..e3a52f094f66 100644 --- a/clang-tools-extra/clang-include-fixer/tool/clang-include-fixer.py +++ b/clang-tools-extra/clang-include-fixer/tool/clang-include-fixer.py @@ -211,7 +211,7 @@ def main(): InsertHeaderToVimBuffer(include_fixer_context, text) print("Added #include {0} for {1}.".format(selected, symbol)) except Exception as error: - print(error.message, file=sys.stderr) + print(error, file=sys.stderr) return