From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Welsh Duggan Newsgroups: gmane.emacs.devel Subject: Code in lisp reader and ,. Date: Thu, 09 Feb 2012 16:17:26 -0500 Message-ID: <87zkcrwvtl.fsf@maru.md5i.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1328822260 14377 80.91.229.3 (9 Feb 2012 21:17:40 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 9 Feb 2012 21:17:40 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Feb 09 22:17:40 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RvbN3-0002f1-S6 for ged-emacs-devel@m.gmane.org; Thu, 09 Feb 2012 22:17:38 +0100 Original-Received: from localhost ([::1]:53105 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RvbN3-0006LM-7P for ged-emacs-devel@m.gmane.org; Thu, 09 Feb 2012 16:17:37 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:55077) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RvbN0-0006Jm-PC for emacs-devel@gnu.org; Thu, 09 Feb 2012 16:17:35 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RvbMz-0004Vu-G4 for emacs-devel@gnu.org; Thu, 09 Feb 2012 16:17:34 -0500 Original-Received: from md5i.com ([75.151.244.229]:50893 helo=maru.md5i.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RvbMz-0004U1-8S for emacs-devel@gnu.org; Thu, 09 Feb 2012 16:17:33 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=md5i.com; s=dkim; h=Content-Type:MIME-Version:Message-ID:Date:Subject:To:From; bh=MZ0LE01qJjfuiunS5j9y4shxIEJEO2PrU72l5hPSPKA=; b=V8bk1PfPdesZDkuMjpIWyDDlsHwIRWfondZK6liN3RWIG6oNbqDTsckV0sXu4gohgqCwVXOQ+Wlm3VVVOvvHpzF9dZgj/Dx284qUmNnUpK3sFlJObMAsiEDz1njHAz4e; Original-Received: from md5i by maru.md5i.com with local (Exim 4.77) (envelope-from ) id 1RvbMs-0004pI-Ti for emacs-devel@gnu.org; Thu, 09 Feb 2012 16:17:27 -0500 User-Agent: Gnus/5.11002 (No Gnus v0.20) Emacs/24.0.93 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 75.151.244.229 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:148413 Archived-At: So, in common lisp, ,. is special in quasiquoted forms. It is supposed to work the same as ,@, except that ,. is a hint to the compiler that the argument to ,. may be destructively modified. Hence given: (setq foo '(a b) bar '(c d)) (setq baz `(x ,@foo y ,.bar z)) baz will be (x a b y c d z), foo will be (a b), and bar could be anything under the sun, but is probably either (c d) or (c d z), where (eq bar (cddddr baz)) ==> t. Now, emacs lisp's backquote macro does not handle the ,. form. However, the lisp reader does treat ,. specially: `,.foo ==> (\,\. foo). I suggest that either emacs lisp's backquote macro be modified to handle ,. (most simply by treating it as an alias of ,@), or the special handling for it (lread.c:2838) should be removed. -- Michael Welsh Duggan (md5i@md5i.com)