From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.devel Subject: Re: Is `kbd' idempotent? Date: Wed, 02 Dec 2015 19:33:21 +0100 Message-ID: <87egf41z0u.fsf@web.de> References: <87a8pvqzij.fsf@web.de> <87bnabv6m6.fsf@fencepost.gnu.org> <87610jqxx6.fsf@web.de> <87mvtu6ybe.fsf@web.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1449081228 11680 80.91.229.3 (2 Dec 2015 18:33:48 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 2 Dec 2015 18:33:48 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Dec 02 19:33:39 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 1a4CDi-0005MZ-G0 for ged-emacs-devel@m.gmane.org; Wed, 02 Dec 2015 19:33:38 +0100 Original-Received: from localhost ([::1]:59804 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a4CDh-0003Ed-RS for ged-emacs-devel@m.gmane.org; Wed, 02 Dec 2015 13:33:37 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60038) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a4CDe-0003Dw-Sd for emacs-devel@gnu.org; Wed, 02 Dec 2015 13:33:35 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a4CDb-0003N3-MV for emacs-devel@gnu.org; Wed, 02 Dec 2015 13:33:34 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]:52446) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a4CDb-0003MR-GC for emacs-devel@gnu.org; Wed, 02 Dec 2015 13:33:31 -0500 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1a4CDZ-00054k-Se for emacs-devel@gnu.org; Wed, 02 Dec 2015 19:33:29 +0100 Original-Received: from ip-90-186-3-135.web.vodafone.de ([90.186.3.135]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 02 Dec 2015 19:33:29 +0100 Original-Received: from michael_heerdegen by ip-90-186-3-135.web.vodafone.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 02 Dec 2015 19:33:29 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 22 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: ip-90-186-3-135.web.vodafone.de User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:CvAUrQtO1nE20jBMvBDZa1hZkUE= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 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:195777 Archived-At: Random832 writes: > I do wonder what the use case is, though, that benefits from allowing > the entry of an arbitrary lisp expression instead of just directly > passing the user input to kbd without even a read/eval stage. Are there > key sequences that can't be represented in kbd format that the user will > want to enter as vector literals? Finally, I think that was a good question. It's easy enough to use C-u M-: to insert the evaluation result of an arbitrary expression into the minibuffer, so restricting the input to strings and vectors is fine. But I don't want to force usage of kbd syntax, so I additionally allowed the expression to be of the form (kbd STRING), and only in this special case, there is an evaluation happening. The user can easily define his own version of the thing that calls kbd in every case, so everybody should be happy. Thanks again, Michael.