From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Marco Wahl Newsgroups: gmane.emacs.help Subject: Re: How to delete the parens around a sexp? Date: Tue, 22 Sep 2015 10:38:03 +0200 Organization: Aioe.org NNTP Server Message-ID: <84pp1aalxw.fsf@gmail.com> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1442911219 9016 80.91.229.3 (22 Sep 2015 08:40:19 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 22 Sep 2015 08:40:19 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Sep 22 10:40:18 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 1ZeJ7Z-0000KM-5G for geh-help-gnu-emacs@m.gmane.org; Tue, 22 Sep 2015 10:40:17 +0200 Original-Received: from localhost ([::1]:37684 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZeJ7Y-0006oH-JV for geh-help-gnu-emacs@m.gmane.org; Tue, 22 Sep 2015 04:40:16 -0400 Original-Path: usenet.stanford.edu!news.kjsl.com!feeder.erje.net!1.eu.feeder.erje.net!weretis.net!feeder4.news.weretis.net!news.mixmin.net!aioe.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 32 Original-NNTP-Posting-Host: bhx+BeIjgvCxWXhCS3eatQ.user.speranza.aioe.org Original-X-Complaints-To: abuse@aioe.org User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-Notice: Filtered by postfilter v. 0.8.2 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAD1BMVEX9/P3zn/zqYfve CPz///+XZmJwAAAAAWJLR0QEj2jZUQAAAAlwSFlzAAALEgAACxIB0t1+/AAAAAd0SU1FB94JCBca NKS0JvoAAAD9SURBVDjLnZRbssMgCIYFN2B0A2nYQCv731tFk+KFTHsOD52Ub+Dnljj3D4PoIJiA d36ZIcT8tPxb4mymYuLdzMR8A7YzIvJMsALPS23IoWU8QVBQu2HOVVJTJonwJ4AuY9VAA4A84qVB KuYoN8erVa3AiwhQLc5BNyHkh3jOv76bXMkVD2plAnV9EotkHX4ZULcDERQrLclvv0S1o98Nqnsb dpY+/nXrzcIdMLZrA/ozSN8inpMfvmWa/bKio0x9aQ/lCgLEBaR2ojCfMLRDK7UNRcV8XEeRhtsl Ld8P4DrZJSIpoOwGEQVTvbh/gP1aQyf3G8DbiHDzTRntDTmSOFjmLqzUAAAAGXRFWHRjb21tZW50 AENyZWF0ZWQgd2l0aCBHSU1Q569AywAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAxNC0wOS0wOFQyMzoy Njo1MiswMjowMPcoeH4AAAAldEVYdGRhdGU6bW9kaWZ5ADIwMTQtMDktMDhUMjM6MjY6NTIrMDI6 MDCGdcDCAAAAAElFTkSuQmCC X-Face: &"bk.O^qRpF*sK+/, &mRxu!P61bKc5"jprbZ_Rax6=! I`CX6#kmDJ~k3QZ, 69ZJor.hJCO)QXAv?&~]EP.<'HHmggrk?>ptlgr:`@WB+YuWwL=^Hl7iYYD"J) "/wg9Ps9}&2Dy^/:1V~vvHS+hK0}6P{*i`"Zyx8 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:107275 Archived-At: Hi! Marcin Borkowski writes: > Hi list, > > I'd like to transform this: > > -!-(some gibberish) > > into this: > > -!-some gibberish > > I assume there's no function in Elisp for that, and it's trivial to > write one, but I just wanted to make sure before I code it. raise-sexp > doesn't work, since it gobbles "gibberish" in the above example unless > given a prefix argument, and if you replace "some gibberish" with an > actual sentence, counting words manually is no fun. > > (Note: before anyone tells me how such a transformation doesn't make > sense: I need it for writing in a natural language.) > > TIA, Maybe you can use command paredit-splice-sexp from paredit mode. C-h k M-s in paredit mode yields: M-s runs the command paredit-splice-sexp (found in paredit-mode-map), which is an interactive compiled Lisp function in ‘paredit.el’.