From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.help Subject: RE: hooks and let-bound variables Date: Tue, 23 Jun 2015 14:44:17 -0700 (PDT) Message-ID: <96506ece-5bd9-4750-8abd-128c77cf6c39@default> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1435095894 6351 80.91.229.3 (23 Jun 2015 21:44:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 23 Jun 2015 21:44:54 +0000 (UTC) To: Alan Schmitt , help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Jun 23 23:44:38 2015 Return-path: Envelope-to: geh-help-gnu-emacs@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 1Z7Vzi-0004dK-1s for geh-help-gnu-emacs@m.gmane.org; Tue, 23 Jun 2015 23:44:38 +0200 Original-Received: from localhost ([::1]:47616 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7Vzh-00011i-FP for geh-help-gnu-emacs@m.gmane.org; Tue, 23 Jun 2015 17:44:37 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:41768) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7VzX-00011B-0Q for help-gnu-emacs@gnu.org; Tue, 23 Jun 2015 17:44:27 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z7VzR-00027w-6a for help-gnu-emacs@gnu.org; Tue, 23 Jun 2015 17:44:26 -0400 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:19309) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7VzQ-00027l-VO for help-gnu-emacs@gnu.org; Tue, 23 Jun 2015 17:44:21 -0400 Original-Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id t5NLiJTF023194 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 23 Jun 2015 21:44:19 GMT Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userv0022.oracle.com (8.13.8/8.13.8) with ESMTP id t5NLiIpY017223 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Tue, 23 Jun 2015 21:44:18 GMT Original-Received: from abhmp0010.oracle.com (abhmp0010.oracle.com [141.146.116.16]) by aserv0122.oracle.com (8.13.8/8.13.8) with ESMTP id t5NLiIuF015633; Tue, 23 Jun 2015 21:44:18 GMT In-Reply-To: X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9 (901082) [OL 12.0.6691.5000 (x86)] X-Source-IP: userv0022.oracle.com [156.151.31.74] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 141.146.126.69 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:105108 Archived-At: > I=E2=80=99m trying to get eshell-autojump to work but I=E2=80=99m getting > errors about an undefined variable (curdir). This variable is bound by a > let before a hook is called: Yes, but occurrences of that variable in the function called by the hook ar= e not within the lexical scope of that let. What happens if you add (defvar curdir), to let Emacs know that the variabl= e is to be dynamically scoped?