From nobody Thu May 2 13:51:51 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.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; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1564520936; cv=none; d=zoho.com; s=zohoarc; b=cuLIVXej07QGCK3KUwD5/igYp89aZUis6UHc8mWFjKRO1QidIU2mSoXDslKai/gXRx+af4dA/29JbueVnbNVJHtlQ6tj526KfmoG3xboCWX/JLsc5d6B5RrJTnNGVoMnlC/m/b5Aid6QIYCrazYVovAKGpyoSM+97kyhUUbkRZU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1564520936; h=Content-Type:Cc: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:ARC-Authentication-Results; bh=cOmPk7yEFDj3SEsgE/WwlvA24sF2GVWwYZqgVkD3eQg=; b=WsIr0qlZK8M8+NOk4lONnM15y1qY7olDnFPsrG+00BJH8r5alMePjkZy1nVohA/uz+6HkW7RKe5/BkSwiBvf52yNmrkElHMqNVpxHtsj09bRsV7RUeBriBYZeGDbxRpFfoISNqlJDQrqTM++PBbsykTt5NEP9NvYTS13TzS1bow= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail 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 1564520936131710.8680603761908; Tue, 30 Jul 2019 14:08:56 -0700 (PDT) Received: from localhost ([::1]:36424 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hsZMY-0003SD-Se for importer@patchew.org; Tue, 30 Jul 2019 17:08:50 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39267) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hsZLG-0002Q5-4o for qemu-devel@nongnu.org; Tue, 30 Jul 2019 17:07:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hsZLF-0001Dn-5d for qemu-devel@nongnu.org; Tue, 30 Jul 2019 17:07:30 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37186) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hsZLC-00017k-FA for qemu-devel@nongnu.org; Tue, 30 Jul 2019 17:07:27 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 477E43082E61; Tue, 30 Jul 2019 21:07:20 +0000 (UTC) Received: from localhost (ovpn-116-22.gru2.redhat.com [10.97.116.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id C7DC05D9CA; Tue, 30 Jul 2019 21:07:19 +0000 (UTC) Date: Tue, 30 Jul 2019 18:07:18 -0300 From: Eduardo Habkost To: qemu-devel@nongnu.org Message-ID: <20190730210718.GU4313@habkost.net> References: <20190726120542.9894-1-armbru@redhat.com> <20190726120542.9894-24-armbru@redhat.com> <20190729194414.GG4313@habkost.net> <87d0hreqh3.fsf_-_@dusky.pond.sub.org> <8bea0201-f796-d682-22e6-069985b45523@redhat.com> <0eb2518f-147c-2b47-f48c-3af26bf5d264@redhat.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <0eb2518f-147c-2b47-f48c-3af26bf5d264@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.46]); Tue, 30 Jul 2019 21:07:20 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [RFC] HACKING: Document 'struct' keyword usage 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: , Cc: Paolo Bonzini , Richard Henderson , Markus Armbruster , Peter Maydell Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Sometimes we use the 'struct' keyword to help us reduce dependencies between header files. Document that practice. Signed-off-by: Eduardo Habkost Reviewed-by: Aleksandar Markovic Reviewed-by: Thomas Huth --- I wonder if this is too terse? Should we give examples? --- HACKING | 2 ++ 1 file changed, 2 insertions(+) diff --git a/HACKING b/HACKING index 0fc3e0fc04..112685bdaf 100644 --- a/HACKING +++ b/HACKING @@ -101,6 +101,8 @@ it points to, or it is aliased to another pointer that = is. =20 2.3. Typedefs Typedefs are used to eliminate the redundant 'struct' keyword. +However, the 'struct' keyword may be sometimes used in header +files to avoid unnecessary dependencies between headers. =20 2.4. Reserved namespaces in C and POSIX Underscore capital, double underscore, and underscore 't' suffixes should = be --=20 2.21.0