From patchwork Fri Dec 20 18:28:18 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Max Reitz X-Patchwork-Id: 304248 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 1E2BD2C0096 for ; Sat, 21 Dec 2013 06:28:51 +1100 (EST) Received: from localhost ([::1]:51150 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vu4wu-0006zv-Dy for incoming@patchwork.ozlabs.org; Fri, 20 Dec 2013 13:37:24 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36528) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vu4of-0004KC-Ep for qemu-devel@nongnu.org; Fri, 20 Dec 2013 13:28:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vu4oa-0001a1-5B for qemu-devel@nongnu.org; Fri, 20 Dec 2013 13:28:53 -0500 Received: from mx1.redhat.com ([209.132.183.28]:26736) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vu4oZ-0001Zu-U8 for qemu-devel@nongnu.org; Fri, 20 Dec 2013 13:28:48 -0500 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id rBKISlps010093 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 20 Dec 2013 13:28:47 -0500 Received: from localhost (ovpn-116-19.ams2.redhat.com [10.36.116.19]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id rBKISjVD021978 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Fri, 20 Dec 2013 13:28:46 -0500 From: Max Reitz To: qemu-devel@nongnu.org Date: Fri, 20 Dec 2013 19:28:18 +0100 Message-Id: <1387564104-15315-19-git-send-email-mreitz@redhat.com> In-Reply-To: <1387564104-15315-1-git-send-email-mreitz@redhat.com> References: <1387564104-15315-1-git-send-email-mreitz@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.11 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: Kevin Wolf , Fam Zheng , Stefan Hajnoczi , Max Reitz Subject: [Qemu-devel] [PATCH v7 18/24] qapi: Add "errno" to the list of polluted words X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Using "errno" directly as an identifier results in various syntax errors; therefore it should be added to the list of polluted words. Signed-off-by: Max Reitz --- scripts/qapi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/qapi.py b/scripts/qapi.py index 750e9fb..9b3de4c 100644 --- a/scripts/qapi.py +++ b/scripts/qapi.py @@ -247,7 +247,7 @@ def c_var(name, protect=True): 'and', 'and_eq', 'bitand', 'bitor', 'compl', 'not', 'not_eq', 'or', 'or_eq', 'xor', 'xor_eq']) # namespace pollution: - polluted_words = set(['unix']) + polluted_words = set(['unix', 'errno']) if protect and (name in c89_words | c99_words | c11_words | gcc_words | cpp_words | polluted_words): return "q_" + name return name.replace('-', '_').lstrip("*")