From nobody Sat Jul 5 16:33:51 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=gmail.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 15215286239761015.5599361269973; Mon, 19 Mar 2018 23:50:23 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B5B3B81254; Tue, 20 Mar 2018 06:50:21 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8A12E5D70C; Tue, 20 Mar 2018 06:50:21 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 564241805972; Tue, 20 Mar 2018 06:50:21 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w2K6o1OT019613 for ; Tue, 20 Mar 2018 02:50:01 -0400 Received: by smtp.corp.redhat.com (Postfix) id 8454D60BE3; Tue, 20 Mar 2018 06:50:01 +0000 (UTC) Received: from mx1.redhat.com (ext-mx04.extmail.prod.ext.phx2.redhat.com [10.5.110.28]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 762F25FCA2 for ; Tue, 20 Mar 2018 06:50:01 +0000 (UTC) Received: from mail-wm0-f53.google.com (mail-wm0-f53.google.com [74.125.82.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C2C3A80464 for ; Tue, 20 Mar 2018 06:49:59 +0000 (UTC) Received: by mail-wm0-f53.google.com with SMTP id 139so1275514wmn.2 for ; Mon, 19 Mar 2018 23:49:59 -0700 (PDT) Received: from rst.Home ([2a02:c7d:692a:c500:1ebc:73f3:5f60:b131]) by smtp.gmail.com with ESMTPSA id g38sm1923269wra.77.2018.03.19.23.49.56 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 19 Mar 2018 23:49:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=0iYdIJ+Axaudr0gNItw/mQRrFrcfzYP3KZKc4c2iYDk=; b=KxevZu1yC4nZx3anAMTVbXStAiAfO2p78ahhLrL+A0k1bLGrkpnyMl5045tYCsnngt gqteJxctkEjDpZfNy+xaEkW1nEXN3Rq8Wc1EneSkd8ZeuJpDcjdvdm9GAqhNMwRgHD1h MUL22HzHMwKJeFNbnnIiAWHOcnoFOcUGOHnyo4G6+1rxI/fgMuY9F0QdeXesEGen2coh KscAK74FLWdREP2IZ1e1WQ0cOHuPSZp4FEdTC06EP6Qv9RVLxD+ATsemzFUFZy1h3BO3 X04c0O4e2EwuFOIYro4sMFwXvQg5Iiue+aOVyXE15nA4a4AUh/eZNp42mEyKkDHQKJiU uLVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=0iYdIJ+Axaudr0gNItw/mQRrFrcfzYP3KZKc4c2iYDk=; b=qp0H4HiNKhAlzVVW+JpiT6IOlwOVaF5xdtvFmOitt2fhrCBgxOmRzIgybNM+EKJMu3 qdR4Gz1zZuvAJwjFUIFnsilRr84JpCg/MmXOAXalJsTWwsmfyMRZ2YjR+ZrEnoG59yJ3 DnPD24QQG0aGGASrGawMpTaqPnX9uIlnbdgVoNrKo57Q0DE4Rd26BTdMYmsFXtbthoim 9xysjLKj4EmK9C5Ijzysq8YO/isC5WQd5p8FjfF1q4UODClQCxiSFLPJg5judgnX1wKj /KhBY+VI/2SlaZYF8AWFQiwGdmQOkXxTgqAG/6Mzme9B4S8vSGkytA7We5l9y7WBY68H aQKw== X-Gm-Message-State: AElRT7GbaFMwdozixbLSARW/9Kt8pntZCU1pzfsC65faWrfItZ5tTEfR LChKjSfSlF8q2Y+bmVFTP23G06He X-Google-Smtp-Source: AG47ELtDu4TngQyCMMxIglJdxlKbX0cGvLXElnTZ9Lw9luMc2Yi2rXAL8yCMnBGlGqICAKW5lLSiWA== X-Received: by 10.28.126.20 with SMTP id z20mr1036403wmc.152.1521528598012; Mon, 19 Mar 2018 23:49:58 -0700 (PDT) From: Radostin Stoyanov To: libvir-list@redhat.com Date: Tue, 20 Mar 2018 06:49:07 +0000 Message-Id: <20180320064908.17723-25-rstoyanov1@gmail.com> In-Reply-To: <20180320064908.17723-1-rstoyanov1@gmail.com> References: <20180320064908.17723-1-rstoyanov1@gmail.com> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Tue, 20 Mar 2018 06:50:00 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Tue, 20 Mar 2018 06:50:00 +0000 (UTC) for IP:'74.125.82.53' DOMAIN:'mail-wm0-f53.google.com' HELO:'mail-wm0-f53.google.com' FROM:'rstoyanov1@gmail.com' RCPT:'' X-RedHat-Spam-Score: 0.12 (DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_PASS) 74.125.82.53 mail-wm0-f53.google.com 74.125.82.53 mail-wm0-f53.google.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.28 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-loop: libvir-list@redhat.com Cc: Radostin Stoyanov Subject: [libvirt] [PATCHv2 24/25] apibuild: Remove redundant parentheses X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 20 Mar 2018 06:50:22 +0000 (UTC) X-ZohoMail-DKIM: fail (Computed bodyhash is different from the expected one) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" http://pylint-messages.wikidot.com/messages:c0325 Signed-off-by: Radostin Stoyanov --- docs/apibuild.py | 74 ++++++++++++++++++++++++++++------------------------= ---- 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/docs/apibuild.py b/docs/apibuild.py index 94de13b56..1f9c8f12c 100755 --- a/docs/apibuild.py +++ b/docs/apibuild.py @@ -156,7 +156,7 @@ class identifier: if self.static: r =3D r + " static" if self.module is not None: - r =3D r + " from %s" % (self.module) + r =3D r + " from %s" % self.module if self.info is not None: r =3D r + " " + repr(self.info) if self.extra is not None: @@ -458,7 +458,7 @@ class CLexer: def debug(self): print("Last token: ", self.last) print("Token queue: ", self.tokens) - print("Line %d end: " % (self.lineno), self.line) + print("Line %d end: " % self.lineno, self.line) =20 def token(self): while self.tokens =3D=3D []: @@ -744,20 +744,20 @@ class CParser: =20 if self.comment is None: if not quiet: - self.warning("Missing comment for type %s" % (name)) + self.warning("Missing comment for type %s" % name) return None if not self.comment.startswith('*'): if not quiet: - self.warning("Missing * in type comment for %s" % (name)) + self.warning("Missing * in type comment for %s" % name) return None =20 lines =3D self.comment.split('\n') # Remove lines that contain only single asterisk lines[:] =3D [line for line in lines if line.strip() !=3D '*'] =20 - if lines[0] !=3D "* %s:" % (name): + if lines[0] !=3D "* %s:" % name: if not quiet: - self.warning("Misformatted type comment for %s" % (name)) + self.warning("Misformatted type comment for %s" % name) self.warning(" Expecting '* %s:' got '%s'" % (name, lines= [0])) return None del lines[0] @@ -767,7 +767,7 @@ class CParser: =20 if not (quiet or desc): self.warning("Type comment for %s lack description of the macr= o" - % (name)) + % name) =20 return desc # @@ -786,33 +786,33 @@ class CParser: =20 if self.comment is None: if not quiet: - self.warning("Missing comment for macro %s" % (name)) - return((args, desc)) + self.warning("Missing comment for macro %s" % name) + return args, desc if self.comment[0] !=3D '*': if not quiet: - self.warning("Missing * in macro comment for %s" % (name)) - return((args, desc)) + self.warning("Missing * in macro comment for %s" % name) + return args, desc lines =3D self.comment.split('\n') if lines[0] =3D=3D '*': del lines[0] - if lines[0] !=3D "* %s:" % (name): + if lines[0] !=3D "* %s:" % name: if not quiet: - self.warning("Misformatted macro comment for %s" % (name)) + self.warning("Misformatted macro comment for %s" % name) self.warning(" Expecting '* %s:' got '%s'" % (name, lines= [0])) - return((args, desc)) + return args, desc del lines[0] while lines[0] =3D=3D '*': del lines[0] while len(lines) > 0 and lines[0][0:3] =3D=3D '* @': l =3D lines[0][3:] try: - (arg, desc) =3D l.split(':', 1) + arg, desc =3D l.split(':', 1) desc =3D desc.strip() arg =3D arg.strip() except: if not quiet: - self.warning("Misformatted macro comment for %s" % (na= me)) - self.warning(" problem with '%s'" % (lines[0])) + self.warning("Misformatted macro comment for %s" % nam= e) + self.warning(" problem with '%s'" % lines[0]) del lines[0] continue del lines[0] @@ -841,9 +841,9 @@ class CParser: =20 if quiet =3D=3D 0: if desc =3D=3D "": - self.warning("Macro comment for %s lack description of the= macro" % (name)) + self.warning("Macro comment for %s lack description of the= macro" % name) =20 - return((args, desc)) + return args, desc =20 # # Parse a comment block and merge the information found in the @@ -860,26 +860,26 @@ class CParser: if name in ignored_functions: quiet =3D 1 =20 - (ret, args) =3D description + ret, args =3D description desc =3D "" retdesc =3D "" =20 if self.comment is None: if not quiet: - self.warning("Missing comment for function %s" % (name)) - return(((ret[0], retdesc), args, desc)) + self.warning("Missing comment for function %s" % name) + return (ret[0], retdesc), args, desc if self.comment[0] !=3D '*': if not quiet: - self.warning("Missing * in function comment for %s" % (nam= e)) - return(((ret[0], retdesc), args, desc)) + self.warning("Missing * in function comment for %s" % name) + return (ret[0], retdesc), args, desc lines =3D self.comment.split('\n') if lines[0] =3D=3D '*': del lines[0] - if lines[0] !=3D "* %s:" % (name): + if lines[0] !=3D "* %s:" % name: if not quiet: - self.warning("Misformatted function comment for %s" % (nam= e)) + self.warning("Misformatted function comment for %s" % name) self.warning(" Expecting '* %s:' got '%s'" % (name, lines= [0])) - return(((ret[0], retdesc), args, desc)) + return (ret[0], retdesc), args, desc del lines[0] while lines[0] =3D=3D '*': del lines[0] @@ -887,13 +887,13 @@ class CParser: while len(lines) > 0 and lines[0][0:3] =3D=3D '* @': l =3D lines[0][3:] try: - (arg, desc) =3D l.split(':', 1) + arg, desc =3D l.split(':', 1) desc =3D desc.strip() arg =3D arg.strip() except: if not quiet: - self.warning("Misformatted function comment for %s" % = (name)) - self.warning(" problem with '%s'" % (lines[0])) + self.warning("Misformatted function comment for %s" % = name) + self.warning(" problem with '%s'" % lines[0]) del lines[0] continue del lines[0] @@ -966,12 +966,12 @@ class CParser: self.warning("Function comment for %s lacks descriptio= n of arg %s" % (name, args[i][1])) i =3D i + 1 if retdesc =3D=3D "" and ret[0] !=3D "void": - self.warning("Function comment for %s lacks description of= return value" % (name)) + self.warning("Function comment for %s lacks description of= return value" % name) if desc =3D=3D "": - self.warning("Function comment for %s lacks description of= the function" % (name)) + self.warning("Function comment for %s lacks description of= the function" % name) =20 =20 - return(((ret[0], retdesc), args, desc)) + return (ret[0], retdesc), args, desc =20 def parsePreproc(self, token): if debug: @@ -1362,7 +1362,7 @@ class CParser: try: value =3D "%d" % (int(value) + 1) except: - self.warning("Failed to compute value of enum %s" = % (name)) + self.warning("Failed to compute value of enum %s" = % name) value =3D "" if token[0] =3D=3D "sep" and token[1] =3D=3D ",": if commentsBeforeVal: @@ -1822,7 +1822,7 @@ class CParser: raise Exception() except: self.error(("function '%s' is not allowed to return long, " - "use long long instead") % (name)) + "use long long instead") % name) =20 for param in signature: if "long" in param[0] and "long long" not in param[0]: @@ -2156,7 +2156,7 @@ class docBuilder: name, escape(desc))) self.indexString(name, desc) else: - output.write(" \n" % (name)) + output.write(" \n" % name) output.write(" \n") =20 def serialize_union(self, output, field, desc): @@ -2195,7 +2195,7 @@ class docBuilder: else: output.write(" \n" % (field[1], field[0], desc)) except: - self.warning("Failed to serialize struct %s" % (name)) + self.warning("Failed to serialize struct %s" % name) output.write(" \n") else: output.write("/>\n") --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list