From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andreas Schwab Newsgroups: gmane.emacs.devel Subject: Re: In C code, how do I create and access a (lisp) variable? Date: Thu, 05 Nov 2015 00:39:36 +0100 Message-ID: <87y4ed72rr.fsf@igel.home> References: <20151104210420.GA4618@acm.fritz.box> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1446680412 28673 80.91.229.3 (4 Nov 2015 23:40:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 4 Nov 2015 23:40:12 +0000 (UTC) Cc: Alan Mackenzie , Emacs development discussions To: =?utf-8?Q?Aur=C3=A9lien?= Aptel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Nov 05 00:40:03 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Zu7eq-0001gC-PK for ged-emacs-devel@m.gmane.org; Thu, 05 Nov 2015 00:40:00 +0100 Original-Received: from localhost ([::1]:57689 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zu7eq-0001tO-27 for ged-emacs-devel@m.gmane.org; Wed, 04 Nov 2015 18:40:00 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59404) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zu7ec-0001tH-07 for emacs-devel@gnu.org; Wed, 04 Nov 2015 18:39:46 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zu7eW-0002ce-Tp for emacs-devel@gnu.org; Wed, 04 Nov 2015 18:39:45 -0500 Original-Received: from mail-out.m-online.net ([212.18.0.9]:43254) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zu7eW-0002cN-Nd for emacs-devel@gnu.org; Wed, 04 Nov 2015 18:39:40 -0500 Original-Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 3nrkwV1NQxz3hj3D; Thu, 5 Nov 2015 00:39:38 +0100 (CET) Original-Received: from localhost (dynscan1.mnet-online.de [192.168.6.68]) by mail.m-online.net (Postfix) with ESMTP id 3nrkwV0f6Kzvh1k; Thu, 5 Nov 2015 00:39:38 +0100 (CET) X-Virus-Scanned: amavisd-new at mnet-online.de Original-Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.68]) (amavisd-new, port 10024) with ESMTP id UT4j_XoGf4-5; Thu, 5 Nov 2015 00:39:37 +0100 (CET) X-Auth-Info: Uh71tSp8BTXEr2r4yono7tPcXwa0HFmq6QwqCif0OUO4lbU0hOL0xkPYD11xCxun Original-Received: from igel.home (host-188-174-220-88.customer.m-online.net [188.174.220.88]) by mail.mnet-online.de (Postfix) with ESMTPA; Thu, 5 Nov 2015 00:39:36 +0100 (CET) Original-Received: by igel.home (Postfix, from userid 1000) id 92F0C2C1A6A; Thu, 5 Nov 2015 00:39:36 +0100 (CET) X-Yow: I wish I was on a Cincinnati street corner holding a clean dog! In-Reply-To: (=?utf-8?Q?=22Aur=C3=A9lien?= Aptel"'s message of "Wed, 4 Nov 2015 22:20:55 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 212.18.0.9 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:193251 Archived-At: Aurélien Aptel writes: > I think you're supposed to use DEFVAR_PER_BUFFER for definition and > BVAR for access. DEFVAR_PER_BUFFER and BVAR are only for variables that are part of struct buffer. An ordinary variable can be made buffer-local even if not part of struct buffer. Andreas. -- Andreas Schwab, schwab@linux-m68k.org GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."