From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Pascal J. Bourguignon" Newsgroups: gmane.emacs.devel Subject: Re: adding namespaces to emacs-lisp (better elisp?) Date: Sat, 27 Jul 2013 12:35:17 +0200 Organization: Informatimago Message-ID: <87li4s1eai.fsf@informatimago.com> References: <874nbh2z3y.fsf@ferrier.me.uk> <871u6l2ral.fsf@ferrier.me.uk> <87siz116zo.fsf@ferrier.me.uk> <87mwp90zgi.fsf@ferrier.me.uk> <87d2q50x58.fsf@ferrier.me.uk> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1374925051 3796 80.91.229.3 (27 Jul 2013 11:37:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 27 Jul 2013 11:37:31 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jul 27 13:37:31 2013 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 1V32oU-0005FS-MQ for ged-emacs-devel@m.gmane.org; Sat, 27 Jul 2013 13:37:30 +0200 Original-Received: from localhost ([::1]:55819 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V32oU-0001Dz-BV for ged-emacs-devel@m.gmane.org; Sat, 27 Jul 2013 07:37:30 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51034) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V32oQ-0001C3-2r for emacs-devel@gnu.org; Sat, 27 Jul 2013 07:37:27 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V32oM-0007OE-FO for emacs-devel@gnu.org; Sat, 27 Jul 2013 07:37:25 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:55284) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V31uu-0002Wt-PG for emacs-devel@gnu.org; Sat, 27 Jul 2013 06:40:04 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1V31ut-0007cM-7c for emacs-devel@gnu.org; Sat, 27 Jul 2013 12:40:03 +0200 Original-Received: from amontsouris-651-1-252-173.w92-163.abo.wanadoo.fr ([92.163.83.173]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 27 Jul 2013 12:40:03 +0200 Original-Received: from pjb by amontsouris-651-1-252-173.w92-163.abo.wanadoo.fr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 27 Jul 2013 12:40:03 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 27 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: amontsouris-651-1-252-173.w92-163.abo.wanadoo.fr Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAQMAAABtzGvEAAAABlBMVEUAAAD///+l2Z/dAAAA oElEQVR4nK3OsRHCMAwF0O8YQufUNIQRGIAja9CxSA55AxZgFO4coMgYrEDDQZWPIlNAjwq9 033pbOBPtbXuB6PKNBn5gZkhGa86Z4x2wE67O+06WxGD/HCOGR0deY3f9Ijwwt7rNGNf6Oac l/GuZTF1wFGKiYYHKSFAkjIo1b6sCYS1sVmFhhhahKQssRjRT90ITWUk6vvK3RsPGs+M1RuR mV+hO/VvFAAAAABJRU5ErkJggg== X-Accept-Language: fr, es, en User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) Cancel-Lock: sha1:YmQ1MzM5M2NkZGVmMGQxYTA3NzczOTY5NmFlNzU5MGQwMzU5ZDIzYg== 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:162195 Archived-At: Stefan Monnier writes: >>>> If a namespace package calls intern the symbol is interned in the >>>> private obarray. >>> I'm not sure how you could do that and neither am I sure that would >>> preserve backward compatibility. So without more details of how that >>> would work, it sounds like wishful thinking to me. >> This is the core of my proposal. >> The guts of intern need to be altered to be aware of when it is being >> called in a packaged context. I am currently expecting to be able to do >> this with a file local variable. > > That's easy when the reader calls `intern', but I'm talking about when > the Elisp code itself makes calls to `intern'. Well, (emacs:intern name) is equivalent to (cl:intern name :emacs). The difficult point to deal with is (emacs:intern ":keyword"). You want it to be equivalent to (cl:intern "keyword" :keyword) instead, but this would break some emacs lisp code. You can leave it as (cl:intern name :emacs) but then :keyword and emacs:\:keyword would have to be unified. -- __Pascal Bourguignon__ http://www.informatimago.com/ A bad day in () is better than a good day in {}. You know you've been lisping too long when you see a recent picture of George Lucas and think "Wait, I thought John McCarthy was dead!" -- Dalek_Baldwin