[PATCH] D73312: [lit] Use canonical None test
Yuanfang Chen via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 23 17:01:00 PST 2020
ychen created this revision.
ychen added a reviewer: rnk.
Herald added subscribers: llvm-commits, delcypher.
Herald added a project: LLVM.
According to here
https://stackoverflow.com/questions/3965104/not-none-test-in-python
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D73312
Files:
llvm/utils/lit/lit/TestRunner.py
Index: llvm/utils/lit/lit/TestRunner.py
===================================================================
--- llvm/utils/lit/lit/TestRunner.py
+++ llvm/utils/lit/lit/TestRunner.py
@@ -727,9 +727,9 @@
exe_in_cwd = os.path.join(cmd_shenv.cwd, args[0])
if os.path.isfile(exe_in_cwd):
executable = exe_in_cwd
- if not executable:
+ if executable is None:
executable = lit.util.which(args[0], cmd_shenv.env['PATH'])
- if not executable:
+ if executable is None:
raise InternalShellError(j, '%r: command not found' % args[0])
# Replace uses of /dev/null with temporary files.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D73312.240060.patch
Type: text/x-patch
Size: 680 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200124/bf4c8fb0/attachment.bin>
More information about the llvm-commits
mailing list