[PATCH] D60766: Fixed error message printing in write_cmake_config.py
Dmitri Gribenko via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 16 02:48:16 PDT 2019
gribozavr created this revision.
Herald added subscribers: llvm-commits, mgorny.
Herald added a project: LLVM.
Previously, write_cmake_config.py would raise an error while printing
the error, because `leftovers` in "'\n'.join(leftovers)" is a tuple.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D60766
Files:
llvm/utils/gn/build/write_cmake_config.py
Index: llvm/utils/gn/build/write_cmake_config.py
===================================================================
--- llvm/utils/gn/build/write_cmake_config.py
+++ llvm/utils/gn/build/write_cmake_config.py
@@ -96,7 +96,10 @@
leftovers = var_re.findall(output)
if leftovers:
- print('unprocessed values:\n', '\n'.join(leftovers), file=sys.stderr)
+ print(
+ 'unprocessed values:\n',
+ '\n'.join([x[0] or x[1] for x in leftovers]),
+ file=sys.stderr)
return 1
if not os.path.exists(args.output) or open(args.output).read() != output:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D60766.195343.patch
Type: text/x-patch
Size: 610 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190416/f381d47a/attachment.bin>
More information about the llvm-commits
mailing list