From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Marcin Borkowski Newsgroups: gmane.emacs.help Subject: Re: One-off history for read-string Date: Thu, 24 Sep 2015 18:27:27 +0200 Message-ID: <87wpvfu6j4.fsf@mbork.pl> References: <87y4fwt3vq.fsf@mbork.pl> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1443112813 31284 80.91.229.3 (24 Sep 2015 16:40:13 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 24 Sep 2015 16:40:13 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Sep 24 18:40:06 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 1Zf9Yz-0006w7-7z for geh-help-gnu-emacs@m.gmane.org; Thu, 24 Sep 2015 18:40:05 +0200 Original-Received: from localhost ([::1]:46545 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zf9Yy-0003CY-GJ for geh-help-gnu-emacs@m.gmane.org; Thu, 24 Sep 2015 12:40:04 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45149) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zf9Mz-00008S-1P for help-gnu-emacs@gnu.org; Thu, 24 Sep 2015 12:27:41 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zf9Mv-0006nJ-18 for help-gnu-emacs@gnu.org; Thu, 24 Sep 2015 12:27:40 -0400 Original-Received: from mail.mojserwer.eu ([2a01:5e00:2:52::8]:35565) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zf9Mu-0006nC-QG for help-gnu-emacs@gnu.org; Thu, 24 Sep 2015 12:27:36 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by mail.mojserwer.eu (Postfix) with ESMTP id D86F66F2008 for ; Thu, 24 Sep 2015 18:27:35 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at mail.mojserwer.eu Original-Received: from mail.mojserwer.eu ([127.0.0.1]) by localhost (mail.mojserwer.eu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lAZdKtlKJmld for ; Thu, 24 Sep 2015 18:27:33 +0200 (CEST) Original-Received: from localhost (103-115.echostar.pl [213.156.103.115]) by mail.mojserwer.eu (Postfix) with ESMTPSA id C68E56F2003 for ; Thu, 24 Sep 2015 18:27:33 +0200 (CEST) In-reply-to: X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a01:5e00:2:52::8 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:107317 Archived-At: On 2015-09-24, at 17:47, Stefan Monnier wrote: >> Is it fine to use a temporary, let-bound variable name as the HISTORY >> parameter, or is there a better way for a "history" I only need to read >> from, not to write to? > > It's probably OK, but do declare this variable with (defvar ) > since it shouldn't be lexically bound Ah, I don't use lexical binding in my package. I probably should; thanks for this advice! > Note also that if the user uses nested minibuffers, she may have two > such commands active at the same time, so you may need to generate the > symbol dynamically rather than always use the same symbol. Rather not applicable to my situation. But out of curiosity: what are "nested minibuffers" and where can I read about them? In my Emacs, when I try to issue a command which needs minibuffer while I'm in a minibuffer, I get the message "Command attempted to use minibuffer while in minibuffer". > Stefan Thanks, -- Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Faculty of Mathematics and Computer Science Adam Mickiewicz University