From: Noam Postavsky <npostavs@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 32051@debbugs.gnu.org, Dan Harms <Dan.Harms@xrtrading.com>
Subject: bug#32051: 26.1; grep-regexp-alist on windows
Date: Wed, 4 Jul 2018 15:57:53 -0400 [thread overview]
Message-ID: <CAM-tV-_r937hzMYep-MuisBZcsBSopgxuyPDFxWgO6qF-wDp3w@mail.gmail.com> (raw)
In-Reply-To: <83in5vnf0s.fsf@gnu.org>
On 4 July 2018 at 12:26, Eli Zaretskii <eliz@gnu.org> wrote:
> I don't think I can reproduce this. I've just ran a Grep command
> whose hits look like this:
>
> d:/gnu/emacs/branch/src/callproc.c:214:#ifdef DOS_NT
>
> and they seem to exhibit all the traits of a Grep hit.
Looking at the grep-regexp-alist, it is the case that a filename with
a colon will not be matched when grep doesn't support --null. In the
case where grep does support --null, the NUL byte is displayed like a
colon, so the difference might not leap out at you.
I think the patch below would fix it:
--- i/lisp/progmodes/grep.el
+++ w/lisp/progmodes/grep.el
@@ -381,3 +381,5 @@ grep-regexp-alist
;; [0-9]+ so as to accept ":034:" in file names.
- "\\(?1:[^\n:]+?[^\n/:]\\):[\t ]*\\(?2:[1-9][0-9]*\\)[\t ]*:"
+ "\\(?1:"
+ "\\(?:[a-zA-Z]:\\)?" ; Allow "C:..." for w32.
+ "[^\n:]+?[^\n/:]\\):[\t ]*\\(?2:[1-9][0-9]*\\)[\t ]*:"
"\\)")
next prev parent reply other threads:[~2018-07-04 19:57 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-04 12:14 bug#32051: 26.1; grep-regexp-alist on windows Dan Harms
2018-07-04 16:26 ` Eli Zaretskii
2018-07-04 19:57 ` Noam Postavsky [this message]
2018-07-06 8:51 ` Eli Zaretskii
2018-07-09 21:08 ` Noam Postavsky
2018-07-10 15:57 ` Eli Zaretskii
2018-07-13 1:51 ` Noam Postavsky
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=CAM-tV-_r937hzMYep-MuisBZcsBSopgxuyPDFxWgO6qF-wDp3w@mail.gmail.com \
--to=npostavs@gmail.com \
--cc=32051@debbugs.gnu.org \
--cc=Dan.Harms@xrtrading.com \
--cc=eliz@gnu.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).