From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Philippe Vaucher Newsgroups: gmane.emacs.devel Subject: Re: Add some aliases for re-related functions Date: Mon, 4 May 2020 09:32:06 +0200 Message-ID: References: <7976B8C1-AFC7-4662-B750-6492EB70C0D5@gmail.com> <29721725-0696-4dcf-b5de-36924a5de259@default> <3777996c-7b3f-4d44-9636-f18aaff76a65@default> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000c8e9f205a4cd8833" Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="103709"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Yuan Fu , Stefan Monnier , Emacs developers To: Drew Adams Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon May 04 09:33:39 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 1jVVbe-000QsY-NS for ged-emacs-devel@m.gmane-mx.org; Mon, 04 May 2020 09:33:38 +0200 Original-Received: from localhost ([::1]:51276 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jVVbd-0003Jw-Mk for ged-emacs-devel@m.gmane-mx.org; Mon, 04 May 2020 03:33:37 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:60616) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jVVah-000228-C0 for emacs-devel@gnu.org; Mon, 04 May 2020 03:32:41 -0400 Original-Received: from mail-lf1-x130.google.com ([2a00:1450:4864:20::130]:43851) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jVVad-00006g-Bh for emacs-devel@gnu.org; Mon, 04 May 2020 03:32:35 -0400 Original-Received: by mail-lf1-x130.google.com with SMTP id 188so8821597lfa.10 for ; Mon, 04 May 2020 00:32:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=6lPQeS6NsjjljiEF3plE3WzDApt+GirmBNMbcV477dg=; b=QpHo6ozWsKNeJ+648yGn04hwYInqWB7YWvBLpjXEYYD7BVKEj2/dzPh6wq6tTYzQud mN3vWwKytpkpLmXs2Q4HJ4dIJg6bqzEftQZl62iu+RnfgdXo61q058wPf3Nl8FpOCQxN 5pjA1gcoVzRgrxF2FI5iUHMH2hwtv16YMnkaFoJJumTFsQK98K3lRmk8IYy5gq2kjuPb uJOpMQ4eBfP2tzTiLewpkxLQpyv+tWJYBDIUS7eqaaueMadxmmg2k3YZC/EqlJleA8F+ is9UrgtP6PaocUX17wuLfT3GsX6FYwx/NO85GL6MzOYm5m5ZLApx03aM+OXGiYc/btZo Jj9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=6lPQeS6NsjjljiEF3plE3WzDApt+GirmBNMbcV477dg=; b=skYjyah+XvYGuLW5rp2UHdoCuQk/c+mXfASXlMOHLWdT8SEmjYJD9abUlfP4IguXlX 5P8oOlLzuud+iGUBaPUXlTDZ94w9LyQg77q5pFP9aTERxI1gX6G8KFd8Nm4HUe1lPt7x 8p1AwZeZagWo90D8WI3WyUBM9QbtCFftxsRdY7AiQcVXDuSVQ4Gf2NYhaiLl/IHpihrD sxrmlErUABKJY4j4L7JzH6IGdV62p9Zymcxugm5kPI7M7guBz5qcZCSjjHd8WgHuunl7 YHsiFlqafm1A1jes4dZPHFIRjCKS8PzXVRPDyeYBz63+qllsGXAkKS4xoJ/uZLGCG+Tk t7vA== X-Gm-Message-State: AGi0PuZtfaGEe1ZFvYsuRBLgug4zJA658mTR5dq3yu6bRJ3mAoXLD3pU aRaWxsudEwX6LbUBr1gS6JLoGkaV6zhuVoWWOSU= X-Google-Smtp-Source: APiQypLp4KXkuAMP3rcLRX+SL5p2WqQ2v3hIb1qUqksYFq/6lj+Z0IlB1qs6LVNDNhCDUw7UMt5g0Il3kz+D58H7BGs= X-Received: by 2002:a05:6512:53a:: with SMTP id o26mr10728030lfc.111.1588577553671; Mon, 04 May 2020 00:32:33 -0700 (PDT) In-Reply-To: Received-SPF: pass client-ip=2a00:1450:4864:20::130; envelope-from=philippe.vaucher@gmail.com; helo=mail-lf1-x130.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-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:248792 Archived-At: --000000000000c8e9f205a4cd8833 Content-Type: text/plain; charset="UTF-8" > [Again, please consider using plain-text, not HTML, in your messages.] I try to do that each time, e.g this message should be plain text. Tell me if it isn't. I reply from gmail and select "remove formatting". > > You make it sound like because naming is hard > > bad names are ok > > How did I make it sound like that to you? By systematically showing examples where it's impossible and always rejecting proposals. Also your tone while your say this kinda imply this is a futile endeavor. Maybe it's just me misintepretating tho. > If you look at the particular half-kidding examples > I showed, you might see that they're not screwball. > Nearly all of them are perfectly reasonable. And > that's the point of showing them. > > With a command such as `flush-lines', if we want to > prefix the name, just what is a good prefix? > > Is the command mostly about lines (the type of data > acted on), so perhaps use prefix `lines-'? > > Is it mostly about regexp-matching/searching, so > perhaps use prefix `re-'? > > Is it mostly about deleting text, so perhaps use > prefix `delete-' (as in one of its aliases)? First of all let's agree that nobody here proposed to rename flush-lines. Anyway, if we had to do it I think all your categories are weak IMHO, sure it touches the concept of lines, regexp and deleting but fundamentally it's about modifying buffers. If I had to name it it'd be: keep-lines -> buffer-keep-lines flush-lines -> buffer-flush-lines With more finesse I could argue for `buffer-modif-select` and `buffer-modif-reject` but I'd probably lose you ;-) Philippe --000000000000c8e9f205a4cd8833 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
> [Again, please consider using plain-text, not HTML, i= n your messages.]

I try to do that each time, e.g this m= essage should be plain text. Tell me if it isn't. I reply from gmail an= d select "remove formatting".

> > You make it= sound like because naming is hard
> > bad names are ok
>> How did I make it sound like that to you?

By= systematically showing examples where it's impossible and always rejec= ting proposals. Also your tone while your say this kinda imply this is a fu= tile endeavor. Maybe it's just me misintepretating tho.

<= br>> If you look at the particular half-kidding examples
> I showe= d, you might see that they're not screwball.
> Nearly all of them= are perfectly reasonable.=C2=A0 And
> that's the point of showin= g them.
>
> With a command such as `flush-lines', if we wan= t to
> prefix the name, just what is a good prefix?
>
> I= s the command mostly about lines (the type of data
> acted on), so pe= rhaps use prefix `lines-'?
>
> Is it mostly about regexp-ma= tching/searching, so
> perhaps use prefix `re-'?
>
> = Is it mostly about deleting text, so perhaps use
> prefix `delete-= 9; (as in one of its aliases)?

First of all let= 9;s agree that nobody here proposed to rename flush-lines.

Anyway, if we had to do it I think all your categories are weak IM= HO, sure it touches the concept of lines, regexp and deleting but fundament= ally it's about modifying buffers. If I had to name it it'd be:

keep-lines -> buffer-keep-lines
flush-li= nes -> buffer-flush-lines

With more finesse= I could argue for `buffer-modif-select` and `buffer-modif-reject` but I= 9;d probably lose you ;-)

Philippe
--000000000000c8e9f205a4cd8833--