Linux-btrace Development Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Vincent Legoll <vincent.legoll@gmail.com>
To: linux-btrace@vger.kernel.org
Subject: [PATCH 08/10] bno_plot.py: Fix pylint: len-as-condition
Date: Fri, 20 Mar 2020 21:44:57 +0000	[thread overview]
Message-ID: <20200320214459.7760-9-vincent.legoll@gmail.com> (raw)

Do not use `len(SEQUENCE)` to determine if a sequence is empty

Signed-off-by: Vincent Legoll <vincent.legoll@gmail.com>
---
 btt/bno_plot.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/btt/bno_plot.py b/btt/bno_plot.py
index 1a1937c..be64da0 100644
--- a/btt/bno_plot.py
+++ b/btt/bno_plot.py
@@ -76,7 +76,7 @@ def parse_args(in_args):
 		elif o in ('-K', '--keys-below'):
 			keys_below = True
 
-	if len(args) > 0:	bnos = args
+	if args:	bnos = args
 	else:			bnos = glob.glob('blknos*[rw].dat')
 
 	return (bnos, keys_below)
-- 
2.20.1

                 reply	other threads:[~2020-03-20 21:44 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200320214459.7760-9-vincent.legoll@gmail.com \
    --to=vincent.legoll@gmail.com \
    --cc=linux-btrace@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).