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: Tue, 01 Dec 2015 19:32:15 +0100 Message-ID: <87io4inhow.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 1448994791 7839 80.91.229.3 (1 Dec 2015 18:33:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 1 Dec 2015 18:33:11 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Dec 01 19:33:02 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 1a3pjZ-0007oV-BG for ged-emacs-devel@m.gmane.org; Tue, 01 Dec 2015 19:33:01 +0100 Original-Received: from localhost ([::1]:54329 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a3pjY-0000em-OB for ged-emacs-devel@m.gmane.org; Tue, 01 Dec 2015 13:33:00 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38350) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a3pjJ-0000eh-IB for emacs-devel@gnu.org; Tue, 01 Dec 2015 13:32:46 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a3pjE-0005we-JU for emacs-devel@gnu.org; Tue, 01 Dec 2015 13:32:45 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]:53676) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a3pjE-0005wW-55 for emacs-devel@gnu.org; Tue, 01 Dec 2015 13:32:40 -0500 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1a3pj7-000761-P1 for emacs-devel@gnu.org; Tue, 01 Dec 2015 19:32:34 +0100 Original-Received: from ip-90-186-3-210.web.vodafone.de ([90.186.3.210]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 01 Dec 2015 19:32:33 +0100 Original-Received: from michael_heerdegen by ip-90-186-3-210.web.vodafone.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 01 Dec 2015 19:32:33 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 25 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: ip-90-186-3-210.web.vodafone.de User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:0SZHbsiHTxkdpoyndikDCmTxVlU= 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:195695 Archived-At: Random832 writes: > What about calling kbd only if the 'read' result is a string? That way > if they really want to pass a self-made string, they can do e.g. > (identity "foo"), whereas "foo" alone will be treated as (kbd "foo") I want to avoid to introduce such a complexity for that little gain. >From what I heard, I think it's cleaner to let the user type the `kbd' call if he prefers the `kbd' format. > 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? The input can be inserted via copy and paste or another method different from typing literally. Also the binding of a variable or the result of something like (my-private-version-of-kbd KEYS ...) should be supported. Thanks, Michael.