From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Vladimir Sedach Newsgroups: gmane.emacs.devel Subject: Re: Proper namespaces in Elisp Date: Fri, 08 May 2020 10:59:00 -0700 Message-ID: <87a72i2tqz.fsf@t510.orion.oneofus.la> References: <87ftcee7td.fsf@tromey.com> <87pnbgzdmx.fsf@tromey.com> <87lfm3290o.fsf@tromey.com> <87ftcb37jx.fsf@t510.orion.oneofus.la> <87d07f2kze.fsf@t510.orion.oneofus.la> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="101053"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.3.10; emacs 26.2 Cc: Tom Tromey , Stefan Monnier , emacs-devel To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri May 08 20:13:22 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jX7Uw-000QAm-Qy for ged-emacs-devel@m.gmane-mx.org; Fri, 08 May 2020 20:13:22 +0200 Original-Received: from localhost ([::1]:57182 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jX7Uv-0006i4-SJ for ged-emacs-devel@m.gmane-mx.org; Fri, 08 May 2020 14:13:21 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58322) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jX7UO-0006Gw-7b for emacs-devel@gnu.org; Fri, 08 May 2020 14:12:48 -0400 Original-Received: from forward105j.mail.yandex.net ([5.45.198.248]:39125) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jX7UM-0008Oz-BQ for emacs-devel@gnu.org; Fri, 08 May 2020 14:12:47 -0400 Original-Received: from forward102q.mail.yandex.net (forward102q.mail.yandex.net [IPv6:2a02:6b8:c0e:1ba:0:640:516:4e7d]) by forward105j.mail.yandex.net (Yandex) with ESMTP id 4C0F6B20C84; Fri, 8 May 2020 21:12:42 +0300 (MSK) Original-Received: from mxback5q.mail.yandex.net (mxback5q.mail.yandex.net [IPv6:2a02:6b8:c0e:1ba:0:640:b716:ad89]) by forward102q.mail.yandex.net (Yandex) with ESMTP id 457097F20013; Fri, 8 May 2020 21:12:42 +0300 (MSK) Original-Received: from vla5-47b3f4751bc4.qloud-c.yandex.net (vla5-47b3f4751bc4.qloud-c.yandex.net [2a02:6b8:c18:3508:0:640:47b3:f475]) by mxback5q.mail.yandex.net (mxback/Yandex) with ESMTP id wYfztAIKMj-Cfsi046V; Fri, 08 May 2020 21:12:42 +0300 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oneofus.la; s=mail; t=1588961562; bh=A2ZfV0bvJqhHmY10MfD2UtVQ3szuChVb5z+r2z/rx3Q=; h=In-reply-to:Subject:Cc:To:From:Date:References:Message-ID; b=A9m/aFNAKFkR8Wlgis5PvaPhZkrPkdOf8lDFhHEt8c2zPDFZJr9SenOW6t+XdWuDy dcrZG1WKkBUNUx6UlrzyxqbyZh9Q0fqvDVO50grOhBVE8QKu27ETqG4vhmh7dHQLvv LcDjb1SfnDfaQlupD1qdginiuLdyAwh85D9Yyji8= Authentication-Results: mxback5q.mail.yandex.net; dkim=pass header.i=@oneofus.la Original-Received: by vla5-47b3f4751bc4.qloud-c.yandex.net (smtp/Yandex) with ESMTPSA id uLRsoiO8qd-Cd24tIhg; Fri, 08 May 2020 21:12:40 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) In-reply-to: Received-SPF: pass client-ip=5.45.198.248; envelope-from=vas@oneofus.la; helo=forward105j.mail.yandex.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/08 14:12:42 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:249310 Archived-At: Jo=C3=A3o T=C3=A1vora writes: > I was talking about grep. With grep you still know to search for SYMBOL because you know where NAMESPACE ends and SYMBOL begins when you delimited namespaces explicitly, like NAMESPACE:SYMBOL > Again this comes with the problem, I don't think it's even worth > discussing. It affects debugging Elisp code, so it is very much worth discussing. >> A question related to isearch: how would the proposed system work >> with apropos? > > The actual symbol is always the longhand version. So apropos would do the prefix abbreviation to symbol name translation? >> I am sorry, I don't follow. The proposal is for a file-local setting >> that requires magic comments. Why wouldn't package authors be >> required to change their code > > We can try to guess notable cases like s.el if they use the cookie > ;; Package-Requires or even by watching the "require" calls. Let me ask this a different way: Who determines what prefix abbreviation to use for a given package? Does the library author declare that "jennys-awesome-string-library" has a prefix abbreviation of "jasl-" that everyone is obligated to use, or does each user of the library declare the prefix abbreviation when they require the library? What delimits the scope of when the prefix abbreviation is active in the reader? Can you be more specific about the algorithm for "try to guess notable cases"? Why is the prefix abbreviation declared with magic comments (bad), but the use of the prefix abbreviation with a require s-expression (good)? There are other ways to load code other than require. How does this proposal work load/eval/etc.? -- Vladimir Sedach Software engineering services in Los Angeles https://oneofus.la