unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Andreas Schwab <schwab@linux-m68k.org>
To: Dmitry Gutov <dmitry@gutov.dev>
Cc: "Randy Taylor" <dev@rjt.dev>, "Yuan Fu" <casouri@gmail.com>,
	"Mattias Engdegård" <mattias.engdegard@gmail.com>,
	"Theodor Thornhill" <theo@thornhill.no>,
	"Basil Contovounesios" <contovob@tcd.ie>,
	64019@debbugs.gnu.org, "Daniel Colascione" <dancol@dancol.org>
Subject: bug#64019: 29.0.91; Fix some tree-sitter :match regexps
Date: Sat, 17 Jun 2023 08:48:20 +0200	[thread overview]
Message-ID: <87sfaqwpmz.fsf@linux-m68k.org> (raw)
In-Reply-To: <66e6d003-8822-962d-c3c0-3636ee1b03a3@gutov.dev> (Dmitry Gutov's message of "Sat, 17 Jun 2023 05:00:24 +0300")

On Jun 17 2023, Dmitry Gutov wrote:

> On 15/06/2023 20:17, Basil Contovounesios wrote:
>> Mattias also spotted the following in
>> https://github.com/mattiase/relint/pull/14:
>> -                              (:match "\\`?[#\"'`:?]" @char))
>> +                              (:match "\\`\\?[#\"'`:?]" @char))
>
> I don't mind, but it seems like both versions do the same thing:
>
> (string-match-p "\\`?!" "?!") => 0
>
> (string-match-p "\\`?!" "!") => nil

This depends on `?' being treated as an ordinary character if occuring
in a context where the special meaning does not make sense, which is
poor practice.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."





  reply	other threads:[~2023-06-17  6:48 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-12 14:25 bug#64019: 29.0.91; Fix some tree-sitter :match regexps Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-12 14:48 ` Mattias Engdegård
2023-06-12 15:10   ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-12 15:37     ` Eli Zaretskii
2023-06-12 20:22       ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-13  2:36         ` Eli Zaretskii
2023-06-13 13:51           ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-12 16:07     ` Mattias Engdegård
2023-06-12 21:39       ` Dmitry Gutov
2023-06-13  7:47         ` Mattias Engdegård
2023-06-13 17:06           ` Dmitry Gutov
2023-06-12 21:33 ` Dmitry Gutov
2023-06-13  2:37   ` Eli Zaretskii
2023-06-13 14:08   ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-13 17:06     ` Dmitry Gutov
2023-06-15 17:17     ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-17  2:00       ` Dmitry Gutov
2023-06-17  6:48         ` Andreas Schwab [this message]
2023-06-17  8:39           ` Mattias Engdegård
2023-06-17 12:21             ` Mattias Engdegård
2023-06-17 15:44             ` Dmitry Gutov
2023-06-17 16:13               ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-17 16:34                 ` Eli Zaretskii
2023-06-17 16:56                   ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-17 17:35                     ` Eli Zaretskii
2023-06-17 19:54                       ` Basil Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-30 12:46                       ` Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-30 12:59                         ` Eli Zaretskii
2023-07-30 16:04                           ` Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87sfaqwpmz.fsf@linux-m68k.org \
    --to=schwab@linux-m68k.org \
    --cc=64019@debbugs.gnu.org \
    --cc=casouri@gmail.com \
    --cc=contovob@tcd.ie \
    --cc=dancol@dancol.org \
    --cc=dev@rjt.dev \
    --cc=dmitry@gutov.dev \
    --cc=mattias.engdegard@gmail.com \
    --cc=theo@thornhill.no \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).