From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: Qs on free variable occurrences Date: Sun, 07 May 2006 01:00:52 -0400 Message-ID: References: Reply-To: rms@gnu.org NNTP-Posting-Host: main.gmane.org Content-Type: text/plain; charset=ISO-8859-15 X-Trace: sea.gmane.org 1146978082 32766 80.91.229.2 (7 May 2006 05:01:22 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 7 May 2006 05:01:22 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun May 07 07:01:20 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FcbOM-0002Mq-OF for ged-emacs-devel@m.gmane.org; Sun, 07 May 2006 07:01:15 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FcbOM-0006bv-DN for ged-emacs-devel@m.gmane.org; Sun, 07 May 2006 01:01:14 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FcbO2-0006Z1-PH for emacs-devel@gnu.org; Sun, 07 May 2006 01:00:54 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FcbO1-0006XY-U5 for emacs-devel@gnu.org; Sun, 07 May 2006 01:00:54 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FcbO1-0006XV-KF for emacs-devel@gnu.org; Sun, 07 May 2006 01:00:53 -0400 Original-Received: from [199.232.76.164] (helo=fencepost.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.52) id 1FcbOY-0007HW-QP for emacs-devel@gnu.org; Sun, 07 May 2006 01:01:26 -0400 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.34) id 1FcbO0-0002Tx-Lb; Sun, 07 May 2006 01:00:52 -0400 Original-To: "Drew Adams" In-reply-to: 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:54022 Archived-At: 4. Byte-compiling the file gives no warning of the variable being used as a free variable (in #3 and #4). This is not a criticism, but a couple of questions. a. Why #4? Is it because the byte-compiler cannot detect these as free occurrences of the variable or is it intentional (TRT)? If the latter, what's the rationale? It is because the variable has a definition elsewhere. (In the C code.) I will add a comment to say so. b. Is this coding style considered good or bad? In particular, should `minibuffer-history-position' be declared a global variable by giving it a defvar? If it weren't used in the C code, that's what we'd do.