GNU bug report logs - #31231
Symbol search broken in NEWS and ChangeLogs

Previous Next

Package: emacs;

Reported by: Juri Linkov <juri <at> linkov.net>

Date: Sat, 21 Apr 2018 20:24:02 UTC

Severity: normal

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Juri Linkov <juri <at> linkov.net>
Cc: 31231 <at> debbugs.gnu.org
Subject: bug#31231: Symbol search broken in NEWS and ChangeLogs
Date: Sun, 22 Apr 2018 20:13:56 +0300
> From: Juri Linkov <juri <at> linkov.net>
> Date: Sat, 21 Apr 2018 23:21:05 +0300
> 
> Symbol search ‘M-s _’ fails to find symbols in NEWS and ChangeLogs where
> symbols are quoted by apostrophes whose syntax is word-constituent.

These files use modes that are descendants of text-mode, so the notion
of a symbol in general makes little sense there.  IOW, this is plain
text, not a program.

> 1. Modify syntax tables to redefine syntax of ‘'’ back to its default
>    that is punctuation or to expression quote:
> 
>    (defvar change-log-mode-syntax-table
>      (let ((st (make-syntax-table)))
>        (modify-syntax-entry ?' "'   " st)
>        st)
>      "Syntax table used while in `change-log-mode'.")
> 
> This solution is not applicable to NEWS files where
> text-mode syntax tables are inherited via outline-mode
> whose syntax table can't be changed.
> 
> 2. In these files replace apostrophes by “LEFT SINGLE QUOTATION MARK” and
>    “RIGHT SINGLE QUOTATION MARK” like are used in Info and Help buffers.

Thanks, but I don't like any of these 2 alternatives.  The first one
will get in the way of spell-checking words with an apostrophe, the
second one will make it harder to view the files on text terminals
that don't support UTF-8.

Is this really such a bad problem that it requires us to tweak
text-based modes?  What happens if you try searching for the symbol as
a simple string? do you get many false positives?




This bug report was last modified 4 years and 325 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.