From nobody Fri Nov 14 00:52:19 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1583516284; cv=none; d=zohomail.com; s=zohoarc; b=ORdorFDNMCgYYKvlJttYwvih+WQi7rhoGvDWSl8rw9RyhZV1HvDKdkQYJb5Dzi2nk9+VCt4Vvsz8T1Gi59x2vAk6WWgH3HNmTZWl/gLe9Ff5mySQOsGkOlqEfqswt9iUBtzac4kVRKFP6TID9tyzfPcz6feZQEtqxlM42VqDKxk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1583516284; h=Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=vrW9XF6BLQAnIhvTlU5HbFtHoyw3EceDEO0yqvg7TFQ=; b=B0BkgcQfVjLM1b3lOUcIcL8aWVhnutpUdYOximD+P6f0UId4xr6FMCiYqpxViCEDsUbXfSMPrOK0if9kKDLh49U1JmBNhNqUZiax+2/tNddSoC9yp2eIHN5lGfHhQY3nPf/f7uuzzG+uX0oi/xQoI2HsqQUcj04KXsiFGfRTwnE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1583516284172430.5908232171247; Fri, 6 Mar 2020 09:38:04 -0800 (PST) Received: from localhost ([::1]:40256 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jAGvD-0000nQ-4h for importer@patchew.org; Fri, 06 Mar 2020 12:38:03 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:50774) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jAGbm-0000aN-Em for qemu-devel@nongnu.org; Fri, 06 Mar 2020 12:17:59 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jAGbl-0007vT-6t for qemu-devel@nongnu.org; Fri, 06 Mar 2020 12:17:58 -0500 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]:36179) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jAGbl-0007tZ-00 for qemu-devel@nongnu.org; Fri, 06 Mar 2020 12:17:57 -0500 Received: by mail-wm1-x32e.google.com with SMTP id i14so3194984wmb.1 for ; Fri, 06 Mar 2020 09:17:56 -0800 (PST) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [81.2.115.148]) by smtp.gmail.com with ESMTPSA id f8sm6948346wmf.20.2020.03.06.09.17.54 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Mar 2020 09:17:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=vrW9XF6BLQAnIhvTlU5HbFtHoyw3EceDEO0yqvg7TFQ=; b=S380BV/+pCVYsEPPtZ1nkWRHqHspAj4EN2Xa4dVV17/hKQf5CDTniObVMlkhp229lY EDm0ixeL8YzfjuFnH8JsUgH98eoHYP5u6joh27Mzun6Pzuy4YP5I5revvJxL4X7QapV1 vgqgls9Ua2lPS7PRC2abb7F6UARCO0/7wQXKTYwEusFW+Mu/5KvDFga6CP4vMRHG4NEB qBP0U7zfo5lAekdgXxD53TezQR8SiwGsCflTTcbCuVvYzUAhIRzrJpKjEjO7M12UAKm+ mpWXXrxwFGvnuIsNtssqLJoNe88r6eUSpoaFVT0u2r7QvpCsEFGr1VTmWCgCtlWYcnGw bwhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=vrW9XF6BLQAnIhvTlU5HbFtHoyw3EceDEO0yqvg7TFQ=; b=XqOB7puLl4dZlWQUDNX7FG6AwrwyR0PjQhoN11r8C8IkQTWIiV7c6N1Z8wNFUYURQH o4OWv8zhmEzPAuKDlVzKDjBCuH74JyORZafrBSUCj836memQN7aCD+knrzaLftatx7+z bs2Ge4iTEhIm7ZRUpcboT996odCR8Y20MzCe8BpGBQIkg1NXcs5dOhoH9xeSibqc849l pWamQrB7zXA0x3vsPWY8LfQ43MkUC3Hg9GBAg2axOr1ratON/+ja1PUnmvXXRuPp3i6L 37MhABGgrJG80Ev1fRK1swfVPSZo1gOOxzJ5KgvtkBTFwuywCKGA17TzypUPtz2cnABh 5IhQ== X-Gm-Message-State: ANhLgQ0HWl42ZF+ySLcxaRPkWsmDEiOeGn4Abp7Wa8R1aPGHje8XqCD0 exvYQp2ukYakQxFmNiHtOc4v8oE133vOzA== X-Google-Smtp-Source: ADFU+vvdSykBeY5TH0fq2JmoCyaJzn3xd6NycMX5Q1lRpGY3T11IZrRcBaIfjosW9MHJ62VQY+RP8g== X-Received: by 2002:a7b:ce18:: with SMTP id m24mr4998902wmc.123.1583515075734; Fri, 06 Mar 2020 09:17:55 -0800 (PST) From: Peter Maydell To: qemu-devel@nongnu.org Subject: [PATCH 4/7] docs/sphinx/hxtool.py: Remove STEXI/ETEXI support Date: Fri, 6 Mar 2020 17:17:46 +0000 Message-Id: <20200306171749.10756-5-peter.maydell@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200306171749.10756-1-peter.maydell@linaro.org> References: <20200306171749.10756-1-peter.maydell@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::32e X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @linaro.org) Content-Type: text/plain; charset="utf-8" Now that none of our input .hx files have STEXI/ETEXI blocks, we can remove the code in the Sphinx hxtool extension that supported parsing them. Signed-off-by: Peter Maydell --- docs/sphinx/hxtool.py | 28 ++++------------------------ 1 file changed, 4 insertions(+), 24 deletions(-) diff --git a/docs/sphinx/hxtool.py b/docs/sphinx/hxtool.py index 7dd223fe362..fb0649a3d5b 100644 --- a/docs/sphinx/hxtool.py +++ b/docs/sphinx/hxtool.py @@ -37,13 +37,11 @@ else: =20 __version__ =3D '1.0' =20 -# We parse hx files with a state machine which may be in one of three -# states: reading the C code fragment, inside a texi fragment, -# or inside a rST fragment. +# We parse hx files with a state machine which may be in one of two +# states: reading the C code fragment, or inside a rST fragment. class HxState(Enum): CTEXT =3D 1 - TEXI =3D 2 - RST =3D 3 + RST =3D 2 =20 def serror(file, lnum, errtext): """Raise an exception giving a user-friendly syntax error message""" @@ -110,31 +108,13 @@ class HxtoolDocDirective(Directive): =20 if directive =3D=3D 'HXCOMM': pass - elif directive =3D=3D 'STEXI': - if state =3D=3D HxState.RST: - serror(hxfile, lnum, 'expected ERST, found STEXI') - elif state =3D=3D HxState.TEXI: - serror(hxfile, lnum, 'expected ETEXI, found STEXI') - else: - state =3D HxState.TEXI - elif directive =3D=3D 'ETEXI': - if state =3D=3D HxState.RST: - serror(hxfile, lnum, 'expected ERST, found ETEXI') - elif state =3D=3D HxState.CTEXT: - serror(hxfile, lnum, 'expected STEXI, found ETEXI') - else: - state =3D HxState.CTEXT elif directive =3D=3D 'SRST': if state =3D=3D HxState.RST: serror(hxfile, lnum, 'expected ERST, found SRST') - elif state =3D=3D HxState.TEXI: - serror(hxfile, lnum, 'expected ETEXI, found SRST') else: state =3D HxState.RST elif directive =3D=3D 'ERST': - if state =3D=3D HxState.TEXI: - serror(hxfile, lnum, 'expected ETEXI, found ERST') - elif state =3D=3D HxState.CTEXT: + if state =3D=3D HxState.CTEXT: serror(hxfile, lnum, 'expected SRST, found ERST') else: state =3D HxState.CTEXT --=20 2.20.1