From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.devel Subject: library prefixes (versus other name prefixes) Date: Sat, 2 May 2020 12:35:59 -0700 (PDT) Message-ID: <73dcba36-03d1-408e-84ac-b07edde8ef77@default> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="12402"; mail-complaints-to="usenet@ciao.gmane.io" To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat May 02 21:36:46 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 1jUxwL-000382-T4 for ged-emacs-devel@m.gmane-mx.org; Sat, 02 May 2020 21:36:45 +0200 Original-Received: from localhost ([::1]:43230 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jUxwK-0007Kt-VZ for ged-emacs-devel@m.gmane-mx.org; Sat, 02 May 2020 15:36:44 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44506) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jUxvl-0006pu-Tx for emacs-devel@gnu.org; Sat, 02 May 2020 15:36:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jUxvk-0008Ng-Q5 for emacs-devel@gnu.org; Sat, 02 May 2020 15:36:09 -0400 Original-Received: from userp2130.oracle.com ([156.151.31.86]:57152) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jUxvk-0008JS-6v for emacs-devel@gnu.org; Sat, 02 May 2020 15:36:08 -0400 Original-Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 042JYu6R040390 for ; Sat, 2 May 2020 19:36:03 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : subject : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=u6UwpHT6svpbzSqPOMr0dic/Pwsypf61/aTcGrkYp/A=; b=NboAPj8bdiFlHnHkQXpmMgfLU5LYfiwh98FKycIe01ATbzzWtwt6qPNM1yN+EbS6rx2A Q8Fp2/46rDMfODA63HjTytLUQQskeT1V6M21Ad0rBmoI64xk7pur364+gHZ8PmBo8o8r A4aXYMMSDgr5tjoAL0gZXJPfymZcwRn1yfgd1/WEbjfNQahJrUT2BF0DZHdNq9CpHeoo PXYmh0i/f79x3aP8GSzQayWx9uLvxtxxxDDN0AW8RLvyHeBPh6z3H7L8eeRf4JZ8xbTJ qELra81Jm5L76PPoPKrRuZZO9Y8/fOFmLyHwPh4NXIWQ8tbgOaUKDzL1eXMZCsO83hSw OQ== Original-Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by userp2130.oracle.com with ESMTP id 30s09qss9q-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Sat, 02 May 2020 19:36:03 +0000 Original-Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 042JZb1U089715 for ; Sat, 2 May 2020 19:36:03 GMT Original-Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by userp3030.oracle.com with ESMTP id 30rwyskvbw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Sat, 02 May 2020 19:36:02 +0000 Original-Received: from abhmp0014.oracle.com (abhmp0014.oracle.com [141.146.116.20]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 042Ja0If015106 for ; Sat, 2 May 2020 19:36:02 GMT X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4993.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9609 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=999 bulkscore=0 phishscore=0 malwarescore=0 spamscore=0 adultscore=0 mlxscore=0 suspectscore=1 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2005020170 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9609 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 mlxscore=0 lowpriorityscore=0 spamscore=0 adultscore=0 clxscore=1015 suspectscore=1 priorityscore=1501 malwarescore=0 mlxlogscore=999 phishscore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2005020170 Received-SPF: pass client-ip=156.151.31.86; envelope-from=drew.adams@oracle.com; helo=userp2130.oracle.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/02 12:51:55 X-ACL-Warn: Detected OS = Linux 3.x [generic] [fuzzy] X-Received-From: 156.151.31.86 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:248552 Archived-At: Some of the discussion in threads "handling many matches", "Imports / inclusion of s.el into Emacs", and now "Add some aliases for re-related functions" considers the use of a thing-type name as prefix for function, var, etc. names. For example, it's proposed to add aliases that use prefix `re-' for regexp-related functions. Currently, I see only these functions with that prefix: re-builder (command) re-search-backward (command) re-search-backward-lax-whitespace=20 re-search-forward (command) re-search-forward-lax-whitespace I asked myself the question, "What if someone wanted to add a library/package that uses prefix `re-'? Already taken, in effect, and not for a library. Too bad. How do we tell a library prefix from another kind of prefix, including one that refers to a type of thing returned or accepted as arg? We can't, on the face of it. So I wonder if it isn't time to reconsider the convention of ending a library prefix with `-'. I know that some libraries out there do use a different char, in particular `/'. Should we change to that? (I'm thinking maybe yes.) If so, should we rename existing library prefixes to respect that new convention? (I'd say no.) ___ What about this proposal: 1. Change the library-prefix convention to use `/' instead of `-'. So instead of `mylib-foo' the name would be `mylib/foo'. 2. Say that the prefix should have at least 2 chars, besides the `/'. So `s/foo' and `/foo' wouldn't conform. 3. "Internal" names would still use `-', after the prefix. So instead of `mylib--foo' the name would be `mylib/-foo'. What would be some pros & cons in making such a change?