From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Patch for fields of `struct buffer' Date: Fri, 28 Jan 2011 09:55:56 -0500 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1296226574 20231 80.91.229.12 (28 Jan 2011 14:56:14 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 28 Jan 2011 14:56:14 +0000 (UTC) Cc: Emacs discussions To: Tom Tromey Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jan 28 15:56:09 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Pipk7-0002BC-BG for ged-emacs-devel@m.gmane.org; Fri, 28 Jan 2011 15:56:07 +0100 Original-Received: from localhost ([127.0.0.1]:35929 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pipk6-0005LG-Uc for ged-emacs-devel@m.gmane.org; Fri, 28 Jan 2011 09:56:07 -0500 Original-Received: from [140.186.70.92] (port=60096 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pipjz-0005It-F9 for emacs-devel@gnu.org; Fri, 28 Jan 2011 09:56:00 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pipjy-0005H6-6n for emacs-devel@gnu.org; Fri, 28 Jan 2011 09:55:59 -0500 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:58450 helo=ironport2-out.pppoe.ca) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pipjx-0005H1-VQ for emacs-devel@gnu.org; Fri, 28 Jan 2011 09:55:58 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvsEAApoQk1FpY7U/2dsb2JhbACkf3S8BoVPBIUYj2g X-IronPort-AV: E=Sophos;i="4.60,392,1291611600"; d="scan'208";a="89565189" Original-Received: from 69-165-142-212.dsl.teksavvy.com (HELO ceviche.home) ([69.165.142.212]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 28 Jan 2011 09:55:56 -0500 Original-Received: by ceviche.home (Postfix, from userid 20848) id 78DBF660DC; Fri, 28 Jan 2011 09:55:56 -0500 (EST) In-Reply-To: (Tom Tromey's message of "Thu, 27 Jan 2011 13:18:37 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.181 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:135149 Archived-At: > Here is the promised change to buffer fields. Please make the "#define BUF_FOO(BUF) ((BUF)->foo_)" to be auto-generated (they could go into global.h). Oh and the arg shojuld be `buf' rather than `BUF'. I'd also be happier if the buffer.h code that defines the fields used names without _ (so they'd have to be passed to a macro that adds the _). Similarly the alloc.c code should ideally not hard-code the "add an _" at every use but instead use some kind of macro call like BUFFER_INTERNAL_FIELD(foo) that would return "foo_". Stefan