From 087bc506d25b20b759a092a7490942e9cb212720 Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Sun, 5 Nov 2017 07:01:53 +0100 Subject: Simplify redundant 'is (not) None' tests in examples --- examples/allnoconfig.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'examples/allnoconfig.py') diff --git a/examples/allnoconfig.py b/examples/allnoconfig.py index 467f681..47a8026 100644 --- a/examples/allnoconfig.py +++ b/examples/allnoconfig.py @@ -18,7 +18,7 @@ def do_allnoconfig(node): # entries in the menuconfig interface, setting each to n (or the lowest # assignable value). - while node is not None: + while node: if isinstance(node.item, Symbol): sym = node.item @@ -33,7 +33,7 @@ def do_allnoconfig(node): changed = True # Recursively lower children - if node.list is not None: + if node.list: do_allnoconfig(node.list) node = node.next -- cgit v1.2.3