From nobody Sat Jul 5 16:10:52 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 1521528599563376.73507448603175; Mon, 19 Mar 2018 23:49:59 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 4399880461; Tue, 20 Mar 2018 06:49:58 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0D9D6C5DA7; Tue, 20 Mar 2018 06:49:58 +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 C2EB14CAA2; Tue, 20 Mar 2018 06:49:57 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w2K6nTS9019367 for ; Tue, 20 Mar 2018 02:49:29 -0400 Received: by smtp.corp.redhat.com (Postfix) id B14D05D724; Tue, 20 Mar 2018 06:49:29 +0000 (UTC) Received: from mx1.redhat.com (ext-mx02.extmail.prod.ext.phx2.redhat.com [10.5.110.26]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A8D995DA62 for ; Tue, 20 Mar 2018 06:49:26 +0000 (UTC) Received: from mail-wr0-f196.google.com (mail-wr0-f196.google.com [209.85.128.196]) (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 7F1AE883B4 for ; Tue, 20 Mar 2018 06:49:25 +0000 (UTC) Received: by mail-wr0-f196.google.com with SMTP id c24so462455wrc.6 for ; Mon, 19 Mar 2018 23:49:25 -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.22 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 19 Mar 2018 23:49:22 -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=+qhSd8+FLJbcsdWvKcd/oyNGyhTmPcQQpTESqCj05Fs=; b=kbhtd4rKMZrcqkdqngis48gOsPomYaczcPFDtBRHj1E3KZdkL3aaj2cVzuq6LUIKW8 yPni/KvMObe4sH+GC+x0aE1FHzuHGsWoobRt02/y4o/JaAzJiQZJ+KfIzzwIgtuXQjgm qYAOdC98+i76+cOSYjNPZ+IJv9q6Us0pvi3YYXQ4lAMPkCbn090QePyE7gVu8uflm6oD J7KP1lc40c0mlIFnGmWQsvFy/s8lv5LhWIk0oyCONl+7cNaPNYCqm2ezhrWWjTxIiRCR fgEnUyCTbFJ+CPul8WAoCKgZK63BASGM/XUwwtqxPqubiHHXhPuUhhCtKSsI5/g6olia ijbA== 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=+qhSd8+FLJbcsdWvKcd/oyNGyhTmPcQQpTESqCj05Fs=; b=Wc2JVCcxR3q6//YcVLmTWj60Y/wnoVC/4NYgz+9ISB63plhUnuwzemiLM1tB4CKV8Z NfFfoYP2X18MqIi8KvFd3P7tjkmSHrum6rXjfflTMjA9wFz7mjfc7MhYFVEHF0kMTF6e ZTx6JiqQJyD+A8U3romHovePHE/4AUv6czW7A22cwIzLDhEs6C+fILWv7Kp/v2Pp4NB/ BTZ4sEfVe1PSSxWriOyEq0dUxKefdGUZlaw9c/OEQ/yLjqmY+9RGanXADPzCd9gwnVfO H0Qib7l7VKuIor1lwg7x6vtnvWYCxhcPcu9acAwhDlnvbtWx1nIJ37W3EAmIEbSEoBof IImA== X-Gm-Message-State: AElRT7GIBpJ3mFtioEhrSzNxuKbPQiees8FUz1bDajq/0S/ycyA7FmSm yQ8CQAE1eyBdizz4XYxZPJDp1K7I X-Google-Smtp-Source: AG47ELtGRZ9Sucb9FrmVEWIE+7cUD8ZsrFi1nE/uflfPYMp2ybQfxmsbqTjXN8iZZ77ytEKfxfhsbg== X-Received: by 10.223.185.73 with SMTP id b9mr11750793wrg.229.1521528563868; Mon, 19 Mar 2018 23:49:23 -0700 (PDT) From: Radostin Stoyanov To: libvir-list@redhat.com Date: Tue, 20 Mar 2018 06:48:44 +0000 Message-Id: <20180320064908.17723-2-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.26]); Tue, 20 Mar 2018 06:49:25 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Tue, 20 Mar 2018 06:49:25 +0000 (UTC) for IP:'209.85.128.196' DOMAIN:'mail-wr0-f196.google.com' HELO:'mail-wr0-f196.google.com' FROM:'rstoyanov1@gmail.com' RCPT:'' X-RedHat-Spam-Score: 0.139 (DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_PASS) 209.85.128.196 mail-wr0-f196.google.com 209.85.128.196 mail-wr0-f196.google.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.26 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-loop: libvir-list@redhat.com Cc: Radostin Stoyanov Subject: [libvirt] [PATCHv2 01/25] apibuild: Use isinstance for type checking 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.16 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:49:58 +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" The isinstance() function [1] returns true if an object argument is an instance of a classinfo argument or of a direct, indirect subclass thereof. 1: https://docs.python.org/3/library/functions.html#isinstance Signed-off-by: Radostin Stoyanov --- docs/apibuild.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/apibuild.py b/docs/apibuild.py index 17d14a0c5..832f04ab1 100755 --- a/docs/apibuild.py +++ b/docs/apibuild.py @@ -742,7 +742,7 @@ class CParser: return line =20 def cleanupComment(self): - if type(self.comment) !=3D type(""): + if not isinstance(self.comment, str): return # remove the leading * on multi-line comments lines =3D self.comment.splitlines(True) @@ -2223,9 +2223,8 @@ class docBuilder: output.write(" \n") try: for field in self.idx.structs[name].info: --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list