unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Dmitry Gutov <dgutov@yandex.ru>
To: npostavs@users.sourceforge.net, bug#6843 <6843@debbugs.gnu.org>,
	Andreas Schwab <schwab@linux-m68k.org>
Subject: bug#6843: grep-mode and filenames with colons
Date: Thu, 27 Jul 2017 15:10:40 +0300	[thread overview]
Message-ID: <b3ab58d3-c4eb-6243-ddad-a3b201a86b08@yandex.ru> (raw)
In-Reply-To: <87h8xy93lg.fsf@users.sourceforge.net>

On 7/27/17 2:32 AM, npostavs@users.sourceforge.net wrote:

> As noted in the emacs-devel thread, non-GNU greps don't support it.

And we can't always ask the user to install GNU Grep?

If we do need to support both ways, maybe tweak the variable names. As 
of now, they look a bit inconsistent.

I'd prefer to have either grep-with-null-regexp-alist and 
grep-[without-null-]-regexp-alist, or grep-regexp-alist and 
grep-fallback-regexp-alist. Just a suggestion.

>> Any reason to change 2 to 3? Why don't we use a non-capturing group for \0
>> here?
> 
> It's on the next line, I capture the \0 so as to display it with a nicer
> string than "^@".

Oh, right. Thanks.

>>> +     (2 '(face unspecified display ":")))
> 
>> If the numbers are the same, we could keep the variable's name the same as
>> well. As a result, most third-party code would continue to simply work.
> 
> Might be worth using explicitly numbered groups to keep the numbers for
> FILE and COLUMN the same though.

Yes, I think it will be a good idea. Provided we can combine it with 
renaming either of the variables back to grep-regexp-alist. Otherwise, 
any backward compatibility is broken anyway.

>> Compensating for the multitude of variables by eliminating newlines between
>> them doesn't look too hot to me.
> 
> Hmm yeah, I think I had them originally as let-bindings, and then I
> forgot to space them out when converting to defconst.

Thanks in advance.





  reply	other threads:[~2017-07-27 12:10 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-11 11:20 bug#6843: 23.1; grep-mode and filenames with colors Ethan Glasser-Camp
2017-07-26 23:32 ` bug#6843: grep-mode and filenames with colons npostavs
2017-07-27 12:10   ` Dmitry Gutov [this message]
2017-07-27 17:20     ` Eli Zaretskii
2017-07-30 15:01     ` npostavs
2017-08-01 13:28       ` Dmitry Gutov

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=b3ab58d3-c4eb-6243-ddad-a3b201a86b08@yandex.ru \
    --to=dgutov@yandex.ru \
    --cc=6843@debbugs.gnu.org \
    --cc=npostavs@users.sourceforge.net \
    --cc=schwab@linux-m68k.org \
    /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).