From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Kickstarter for Emacs Date: Fri, 20 Apr 2012 22:46:28 -0400 Message-ID: References: <87wr5dfm9v.fsf@gnu.org> <87398118ys.fsf@thinkpad.tsdh.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1334976399 18626 80.91.229.3 (21 Apr 2012 02:46:39 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 21 Apr 2012 02:46:39 +0000 (UTC) Cc: emacs-devel@gnu.org To: Phil Hagelberg Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Apr 21 04:46:38 2012 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 1SLQLM-00071J-Le for ged-emacs-devel@m.gmane.org; Sat, 21 Apr 2012 04:46:36 +0200 Original-Received: from localhost ([::1]:47413 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SLQLL-0007sX-QE for ged-emacs-devel@m.gmane.org; Fri, 20 Apr 2012 22:46:35 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:37601) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SLQLJ-0007sE-E7 for emacs-devel@gnu.org; Fri, 20 Apr 2012 22:46:34 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SLQLG-0000Sb-IU for emacs-devel@gnu.org; Fri, 20 Apr 2012 22:46:32 -0400 Original-Received: from ironport-out.teksavvy.com ([206.248.143.162]:35518) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SLQLG-0000SQ-Dz for emacs-devel@gnu.org; Fri, 20 Apr 2012 22:46:30 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApUIACxOgk/O+K5t/2dsb2JhbABDuCMDgQyBCIIJAQEEAVYjEAs0EhQYDSSIHAW2MosnOoR5BKRFgV2DA4E4 X-IronPort-AV: E=Sophos;i="4.75,391,1330923600"; d="scan'208";a="175684362" Original-Received: from 206-248-174-109.dsl.teksavvy.com (HELO pastel.home) ([206.248.174.109]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 20 Apr 2012 22:46:28 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 5BE1D58E55; Fri, 20 Apr 2012 22:46:28 -0400 (EDT) In-Reply-To: (Phil Hagelberg's message of "Fri, 20 Apr 2012 17:10:33 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.94 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.143.162 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:149889 Archived-At: >>> I'd happily contribute money to the development of the concurrency >>> branch, the xembed work, or immutable strings/data structures. >> Curious: what do you expect "immutable strings/data structures" >> to provide? > I have been thinking about implementing egal from Henry Baker's famous > equality paper[1] in Emacs Lisp, but it is not very practical unless > you can make certain guarantees of immutability. My own local hacked version of Emacs has aset signal an error when called on a string (and subst-char-in-string also signals as error when called with `inplace'). I rarely bump into problems because of this change. But note that strings include text-properties, and I still allow those to be changed. Making them immutable would break more code (since until `propertize' was added, all the text-properties were manipulated by side-effects). Now, `equal' does not pay attention to strings's text-properties, so maybe my limited immutability would be good enough for `egal' (which is really what we call `eql' if you think about it). For `cons' cells, side-effects are used much too often in Elisp, I wouldn't hold much hope for making them immutable. So immutable cells would have to be a new type (and car/cdr could be made to work with them as well) with a new constructor (maybe named `icons' or `pair'). The problem still remains: what would be the benefit? Stefan