From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Newsgroups: gmane.emacs.help Subject: Re: on adding a function call to a s-exp Date: Tue, 12 Jun 2018 15:34:21 +0100 Message-ID: References: <864libzkem.fsf@gmail.com> <86zi026stt.fsf@gmail.com> <86wov55r33.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1528814002 29757 195.159.176.226 (12 Jun 2018 14:33:22 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 12 Jun 2018 14:33:22 +0000 (UTC) Cc: "help-gnu-emacs@gnu.org List" To: Robert Girault Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Jun 12 16:33:18 2018 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fSkMF-0007bJ-Ii for geh-help-gnu-emacs@m.gmane.org; Tue, 12 Jun 2018 16:33:15 +0200 Original-Received: from localhost ([::1]:55958 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSkOM-0007LI-Ll for geh-help-gnu-emacs@m.gmane.org; Tue, 12 Jun 2018 10:35:26 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48481) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSkNg-0007IG-F8 for help-gnu-emacs@gnu.org; Tue, 12 Jun 2018 10:34:45 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSkNf-0002pt-Ex for help-gnu-emacs@gnu.org; Tue, 12 Jun 2018 10:34:44 -0400 Original-Received: from mail-io0-x22e.google.com ([2607:f8b0:4001:c06::22e]:40676) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fSkNf-0002pa-7B for help-gnu-emacs@gnu.org; Tue, 12 Jun 2018 10:34:43 -0400 Original-Received: by mail-io0-x22e.google.com with SMTP id g22-v6so28277942iob.7 for ; Tue, 12 Jun 2018 07:34:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=4pmMY+C3ibRnvHnlkLwdRr1RHi0+azDAvODi3tz/Sxw=; b=gqCGRoa/dpJFH5OTZ9JhxWtycanGlcN3pVGKQDSH2jF1KqGCNjmpWNLaAiboqTsbDM edRNZLqe2BUYxlS8ewh7Fie/k6hgMgcAaGWEggIts19/7ibcbOpTL2L+jqy0Cs5H3pC4 WRnqLAMvQRh55O8KD1ml06adS4lKj98hFEUZlam1kwPZssZE7t6s8MS/vFvyprFwseUw M/H5tk2Wtbpm75SL2C6yO9sqW1KLk0qQXTuxTozHQH5kUT4p6jJZCKj8LvAkfEPvF/7I 7O0vUZYGDz5dN5g/t6/444R3o17FLyQvmFyOS8q0m6lbm6am3OL3+VZ1U5Wu63B+iJlo PHDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=4pmMY+C3ibRnvHnlkLwdRr1RHi0+azDAvODi3tz/Sxw=; b=hy80qfTwjcqnfaGKGL/tMKJhUKCQ3O1xaSlm/PhlCGBpvHDQ4ApGzo/UEL1ALuoHcz mmcbKSAPdH7Whd5TayS/C9InxjkNszvChVwDMG3uuz1YTJWk6SalDBeusGvCUtdgnHlz ccJCGT6yt89HMKN8JDSZzYlwcOP4yyQ+/GSyq8DyM8m2dMS4Mcu2bcqx8klBtmd5daUW 8fw6tJKfFFkY7rRZz7z+p6z3acccyVCy1AFdZu+orW55gBPmPb8peBVR0qhAhEEj9HX2 NiYP/pr+tcBd251U4EP/mMFF86ngUz3VNfS8HJ+HpYJ8mlcs2+iDY3tuq0brBhTBm+eA +W8g== X-Gm-Message-State: APt69E2nES7D/1hdmcYRh8Hm0OYjgaPNauAZqNv4LLAIq+BqooK7S3+x MvxXdolzmX/yz5qo5h/rMf9dhCPhyRQ76j8fqys= X-Google-Smtp-Source: ADUXVKKKSEV9Ac47LsWnvAXvDgBHmNft/5G2k3jsCajtBUITBOrTukGe4L4mVrt4rsZJ0Y97WG2ykp4ZdBaN2N2xTeg= X-Received: by 2002:a6b:2909:: with SMTP id p9-v6mr770001iop.28.1528814082455; Tue, 12 Jun 2018 07:34:42 -0700 (PDT) Original-Received: by 2002:a4f:2246:0:0:0:0:0 with HTTP; Tue, 12 Jun 2018 07:34:21 -0700 (PDT) In-Reply-To: <86wov55r33.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4001:c06::22e X-Content-Filtered-By: Mailman/MimeDel 2.1.21 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.help:117110 Archived-At: On Mon, Jun 11, 2018 at 3:35 PM, Robert Girault wrote: > Michael Heerdegen writes: > > > Robert Girault writes: > > > >> (show-paren-mode) > >> (electric-pair-mode) > >> (autoload 'enable-paredit-mode "paredit" > >> "Turn on pseudo-structural editing of Lisp code." > >> t) > >> (add-hook 'M-mode-hook 'enable-paredit-mode) > > > > I don't know what M-mode is, but in elisp-lisp-mode and with paredit, > > it's like you want. If you use paredit for Emacs Lisp, you probably > > also don't need electric-pair-mode. > > I confirm this. (Thanks!) > > > Without paredit-mode, AFAICT what you get when you hit M-( is > > `insert-pair' via `insert-parentheses', and that has hardcoded what you > > see. You would have to change `insert-pair' to get what you want - wit= h > > an advice probably. Alternatively, as said, paredit should behave as > > you want without configuration. > > I'll choose to use paredit and learn how to use it properly. (There'll > likely be other good things there that I don't currently know or use.) > I suggest you also give (the newer, 24.4+) eletric-pair-mode a try. It should work consistently in all emacs major modes, not just lisp modes, and is maintained together with Emacs. By default, in emacs-lisp-mode you won't notice a difference to paredit for the most common operations (you *will* notice that it lets you unbalance the buffer temporarily though, but I consider that a feature). disclaimer, if you hadn't figured it out: I wrote it :-) Jo=C3=A3o