From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Re: Do shorthands break basic tooling (tags, grep, etc)? (was Re: Shorthands have landed on master) Date: Thu, 30 Sep 2021 17:37:48 +0000 Message-ID: References: <16338bdc2497fc51c6fb6d54ab370bfb@webmail.orcon.net.nz> <874ka5gsqa.fsf@gnus.org> <25d8d72022b571db5291@heytings.org> <87h7e2xsl5.fsf@gmail.com> <87czoqxpvg.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30864"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Richard Stallman , psainty@orcon.net.nz, emacs-devel@gnu.org, Gregory Heytings , joaotavora@gmail.com, Lars Ingebrigtsen To: =?iso-8859-1?Q?Andr=E9_A=2E?= Gomes Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Sep 30 19:41:06 2021 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 1mW03N-0007nz-Gg for ged-emacs-devel@m.gmane-mx.org; Thu, 30 Sep 2021 19:41:05 +0200 Original-Received: from localhost ([::1]:41812 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mW03L-0002Gi-Qc for ged-emacs-devel@m.gmane-mx.org; Thu, 30 Sep 2021 13:41:03 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41420) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mW00Q-0001RH-76 for emacs-devel@gnu.org; Thu, 30 Sep 2021 13:38:02 -0400 Original-Received: from colin.muc.de ([193.149.48.1]:32097 helo=mail.muc.de) by eggs.gnu.org with smtp (Exim 4.90_1) (envelope-from ) id 1mW00O-00081J-7d for emacs-devel@gnu.org; Thu, 30 Sep 2021 13:38:01 -0400 Original-Received: (qmail 4324 invoked by uid 3782); 30 Sep 2021 17:37:48 -0000 Original-Received: from acm.muc.de (p4fe15a46.dip0.t-ipconnect.de [79.225.90.70]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Thu, 30 Sep 2021 19:37:48 +0200 Original-Received: (qmail 5677 invoked by uid 1000); 30 Sep 2021 17:37:48 -0000 Content-Disposition: inline In-Reply-To: <87czoqxpvg.fsf@gmail.com> X-Submission-Agent: TMDA/1.3.x (Ph3nix) X-Primary-Address: acm@muc.de Received-SPF: pass client-ip=193.149.48.1; envelope-from=acm@muc.de; helo=mail.muc.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no 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:275919 Archived-At: Hello, André. On Thu, Sep 30, 2021 at 14:30:11 +0300, André A. Gomes wrote: > Alan Mackenzie writes: > > On Thu, Sep 30, 2021 at 13:31:34 +0300, André A. Gomes wrote: > >> Gregory Heytings writes: > >> > A simple example: suppose you want to check which ELPA package > >> > activates tab-bar-mode. That's easy to do with "grep -R tab-bar-mode" > >> > in a clone of the ELPA repository. With symbol prefix renaming, a > >> > package author might decide to add ("tb-" . "tab-bar-") in the > >> > shorthands of the package, and "grep -R tab-bar-mode" will not show > >> > anything. Likewise for tag systems, the symbols that are recorded > >> > will possibly be different in each package, and a search for > >> > tab-bar-mode will not return occurrences of tb-mode. > >> I don't think this is a problem. Grep comes the world of Unix and its > >> mantras. But Lisp REPLs come from another world. > >> Using grep and tag systems to reason about a Lisp program is like eating > >> soup with a fork. You can do it, but it's the wrong tool. > > That is a very negative and unhelpful thing to say. Do you have the > > requisite background to say it? What precisely would you use in place > > of grep, which is a powerful, easily learnt, fast, universal tool? > > My experience is that grep is an essential tool for Emacs maintenance. > I'm sorry that my words had a negative impact towards you or others. I > acknowledge and value the efforts of any member of this community. Thanks for saying that! > My words were misinterpreted perhaps. Firstly, I also eat soup with a > fork, i.e. I also grep Lisp source code. But I must be honest with > myself, and admit it's not the right tool. Indeed, grep is a universal > tool that can be used to inspect any textual data. But powerful Lisp > environments (think Slime) are "aware of themselves" and do better than > grep does. For some jobs, I'm sure they will. Possibly even for most jobs. But they have their disadvantages. They're difficult to combine with other tools. They don't run on the command line. They tend to need your code to be instrumented in some fashion first, which is slow. They're difficult and time-consuming to learn, particularly for a special-purpose tool. The environment I have to use in my day job has such tools built in to it, and they're well implemented. But I dislike their constraints. I dislike the precise format (unchangeable) chosen for the output. Now and then, I'd kill to be able to use 'find' and 'grep' on the source files. I don't like integrated development environments. Also, grep is fast. On my 4 year old machine today it took 0.27 seconds to grep through our entire set of Lisp source files, from a cold start. With those files in cache, it took a mere 0.05 seconds. This is effectively instantaneous. > My point is thus simple and far from being original. A culture shock > between "Unix" and Lisp exists, and it has been discussed to death (for > instance in the "UNIX Haters Handbook"). I know that book. :-) Most of the people on this list do both "Unix" and Lisp, and some are experts at both. There's no need to have to chose one or the other, we can use both. > I think shorthands is a good idea. While the grep claim is true, I find > it orthogonal in the sense that we're judging the adoption of a new idea > by the wrong standards. If it is going to cause problems in Emacs development, we should surely discuss those problems in advance and evaluate them, rather than just saying "should be OK, why worry?". We're likely talking about an irreversible change taking place here. It'd better be right. > Again, I apologize. No problems! > -- > André A. Gomes > "Free Thought, Free World" -- Alan Mackenzie (Nuremberg, Germany).