From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: yzhh Newsgroups: gmane.emacs.devel Subject: Re: recording-elisp.el - try recording commands as elisp code Date: Fri, 02 Nov 2007 14:14:05 +0800 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Trace: ger.gmane.org 1193984079 20391 80.91.229.12 (2 Nov 2007 06:14:39 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 2 Nov 2007 06:14:39 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Nov 02 07:14:41 2007 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.50) id 1Inpnj-0003SR-Ai for ged-emacs-devel@m.gmane.org; Fri, 02 Nov 2007 07:14:39 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1InpnZ-0008IE-5C for ged-emacs-devel@m.gmane.org; Fri, 02 Nov 2007 02:14:29 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1InpnV-0008FM-F0 for emacs-devel@gnu.org; Fri, 02 Nov 2007 02:14:25 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1InpnU-0008DR-Da for emacs-devel@gnu.org; Fri, 02 Nov 2007 02:14:24 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1InpnU-0008DE-6Y for emacs-devel@gnu.org; Fri, 02 Nov 2007 02:14:24 -0400 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1InpnT-0008BD-O0 for emacs-devel@gnu.org; Fri, 02 Nov 2007 02:14:24 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1InpnO-0006xS-EM for emacs-devel@gnu.org; Fri, 02 Nov 2007 06:14:18 +0000 Original-Received: from 211.90.238.185 ([211.90.238.185]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 02 Nov 2007 06:14:18 +0000 Original-Received: from yezonghui by 211.90.238.185 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 02 Nov 2007 06:14:18 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 20 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 211.90.238.185 User-Agent: KNode/0.10.5 X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) 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:82341 Archived-At: A question: To get good isearch recording I used isearch internal information (a stack of intermidiate states left on isearch-exit). This looks a bad practice since it's prone to isearch implementation changes. But the situation is: it cannot be done without knowledge about it's internals. Recording every isearch command does not work because many of them do not have args (i.e. they've not been designed to be recorded). And any attempt to transform them to be shorter relies on isearch implementation. The "isearch state stack " is just another kind of interal knowledge and I choose it for simplicity. It's quite contradictory. If I give up relying on internals the recorded result looks bad. If I insist this style there are other isearch-alike commands waiting - I simply can not and should not handle them all. -- regards, yzhh