* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
@ 2016-02-07 20:41 Bastian Beischer
2016-02-08 0:09 ` Bastian Beischer
2016-02-08 0:54 ` Juri Linkov
0 siblings, 2 replies; 12+ messages in thread
From: Bastian Beischer @ 2016-02-07 20:41 UTC (permalink / raw)
To: 22589
Instructions to reproduce:
1) emacs -Q
2) open a new file called "test.c"
3) enter this text:
int main() {
int i = 0;
return 0;
}
4) go to the beginning of the buffer
5) hit M-s _ and search for the symbol "i"
---> The very first character in "int main" is highlighted as a match
even though the first match should be "i" in "int i =0".
In GNU Emacs 25.0.90.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.18.7)
of 2016-02-07 built on bastian-desktop
Repository revision: 67fcd5addcd91169f79dc5d51d0a71eb2b486aed
Windowing system distributor 'The X.Org Foundation', version 11.0.11800000
Configured using:
'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
--localstatedir=/var --mandir=/usr/share/man
--pdfdir=/usr/share/doc/emacs/pdf --with-sound=alsa --without-gconf
--with-x-toolkit=gtk3 --with-xft 'CFLAGS=-march=x86-64 -mtune=generic
-O2 -pipe -fstack-protector-strong' CPPFLAGS=-D_FORTIFY_SOURCE=2
LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro'
Configured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GSETTINGS NOTIFY
ACL GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS
GTK3 X11
Important settings:
value of $LANG: en_US.UTF-8
locale-coding-system: utf-8-unix
Major mode: C++/l
Minor modes in effect:
whitespace-mode: t
subword-mode: t
ggtags-mode: t
function-args-mode: t
projectile-global-mode: t
projectile-mode: t
yas-global-mode: t
yas-minor-mode: t
window-numbering-mode: t
diff-auto-refine-mode: t
magit-auto-revert-mode: t
global-git-commit-mode: t
async-bytecomp-package-mode: t
flx-ido-mode: t
ido-everywhere: t
global-srecode-minor-mode: t
srecode-minor-mode: t
global-semanticdb-minor-mode: t
global-semantic-idle-scheduler-mode: t
semantic-idle-scheduler-mode: t
semantic-decoration-mode: t
global-semantic-decoration-mode: t
semantic-highlight-func-mode: t
global-semantic-highlight-func-mode: t
semantic-stickyfunc-mode: t
global-semantic-stickyfunc-mode: t
semantic-show-parser-state-mode: t
global-semantic-show-parser-state-mode: t
semantic-mode: t
global-ede-mode: t
ede-minor-mode: t
shell-dirtrack-mode: t
show-paren-mode: t
global-hi-lock-mode: t
hi-lock-mode: t
tooltip-mode: t
global-eldoc-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
column-number-mode: t
line-number-mode: t
transient-mark-mode: t
abbrev-mode: t
hs-minor-mode: t
Recent messages:
[yas] Loading for `c++-mode', just-in-time: (lambda nil (yas--load-directory-1 (quote /home/beischer/.emacs.d/snippets/c++-mode) (quote c++-mode)))!
[yas] Loading snippet files from /home/beischer/.emacs.d/snippets/c++-mode
[yas] Loading for `cc-mode', just-in-time: (lambda nil (yas--load-directory-1 (quote /home/beischer/.emacs.d/elpa/yasnippet-20160131.948/snippets/cc-mode) (quote cc-mode)))!
[yas] Loading snippet files from /home/beischer/.emacs.d/elpa/yasnippet-20160131.948/snippets/cc-mode
[yas] Loading for `cc-mode', just-in-time: (lambda nil (yas--load-directory-1 (quote /home/beischer/.emacs.d/snippets/cc-mode) (quote cc-mode)))!
[yas] Loading snippet files from /home/beischer/.emacs.d/snippets/cc-mode
Mark saved where search started [4 times]
Quit
Mark saved where search started
C-c C-c is undefined
Load-path shadows:
/home/beischer/.emacs.d/elpa/helm-20160207.525/helm-multi-match hides /home/beischer/.emacs.d/elpa/helm-core-20160203.219/helm-multi-match
/home/beischer/.emacs.d/elpa/ivy-20150331.36/ivy hides /home/beischer/.emacs.d/elpa/swiper-20160207.229/ivy
/home/beischer/.emacs.d/elpa/cmake-mode-20151012.726/cmake-mode hides /usr/share/emacs/site-lisp/cmake-mode
/usr/share/emacs/site-lisp/various/buff-menu hides /usr/share/emacs/25.0.90/lisp/buff-menu
/home/beischer/.emacs.d/elpa/org-20160201/ob-gnuplot hides /usr/share/emacs/25.0.90/lisp/org/ob-gnuplot
/home/beischer/.emacs.d/elpa/org-20160201/ob-scala hides /usr/share/emacs/25.0.90/lisp/org/ob-scala
/home/beischer/.emacs.d/elpa/org-20160201/org-id hides /usr/share/emacs/25.0.90/lisp/org/org-id
/home/beischer/.emacs.d/elpa/org-20160201/ob-ruby hides /usr/share/emacs/25.0.90/lisp/org/ob-ruby
/home/beischer/.emacs.d/elpa/org-20160201/ob-io hides /usr/share/emacs/25.0.90/lisp/org/ob-io
/home/beischer/.emacs.d/elpa/org-20160201/ob-scheme hides /usr/share/emacs/25.0.90/lisp/org/ob-scheme
/home/beischer/.emacs.d/elpa/org-20160201/ob-awk hides /usr/share/emacs/25.0.90/lisp/org/ob-awk
/home/beischer/.emacs.d/elpa/org-20160201/org-feed hides /usr/share/emacs/25.0.90/lisp/org/org-feed
/home/beischer/.emacs.d/elpa/org-20160201/org-src hides /usr/share/emacs/25.0.90/lisp/org/org-src
/home/beischer/.emacs.d/elpa/org-20160201/ob-fortran hides /usr/share/emacs/25.0.90/lisp/org/ob-fortran
/home/beischer/.emacs.d/elpa/org-20160201/org-element hides /usr/share/emacs/25.0.90/lisp/org/org-element
/home/beischer/.emacs.d/elpa/org-20160201/ox-html hides /usr/share/emacs/25.0.90/lisp/org/ox-html
/home/beischer/.emacs.d/elpa/org-20160201/org-capture hides /usr/share/emacs/25.0.90/lisp/org/org-capture
/home/beischer/.emacs.d/elpa/org-20160201/ob-keys hides /usr/share/emacs/25.0.90/lisp/org/ob-keys
/home/beischer/.emacs.d/elpa/org-20160201/org-w3m hides /usr/share/emacs/25.0.90/lisp/org/org-w3m
/home/beischer/.emacs.d/elpa/org-20160201/org-ctags hides /usr/share/emacs/25.0.90/lisp/org/org-ctags
/home/beischer/.emacs.d/elpa/org-20160201/org-bibtex hides /usr/share/emacs/25.0.90/lisp/org/org-bibtex
/home/beischer/.emacs.d/elpa/org-20160201/ob-exp hides /usr/share/emacs/25.0.90/lisp/org/ob-exp
/home/beischer/.emacs.d/elpa/org-20160201/ob-eval hides /usr/share/emacs/25.0.90/lisp/org/ob-eval
/home/beischer/.emacs.d/elpa/org-20160201/ob-ledger hides /usr/share/emacs/25.0.90/lisp/org/ob-ledger
/home/beischer/.emacs.d/elpa/org-20160201/ob-sass hides /usr/share/emacs/25.0.90/lisp/org/ob-sass
/home/beischer/.emacs.d/elpa/org-20160201/org-table hides /usr/share/emacs/25.0.90/lisp/org/org-table
/home/beischer/.emacs.d/elpa/org-20160201/org-mhe hides /usr/share/emacs/25.0.90/lisp/org/org-mhe
/home/beischer/.emacs.d/elpa/org-20160201/ob-perl hides /usr/share/emacs/25.0.90/lisp/org/ob-perl
/home/beischer/.emacs.d/elpa/org-20160201/org-rmail hides /usr/share/emacs/25.0.90/lisp/org/org-rmail
/home/beischer/.emacs.d/elpa/org-20160201/ox-icalendar hides /usr/share/emacs/25.0.90/lisp/org/ox-icalendar
/home/beischer/.emacs.d/elpa/org-20160201/org-macro hides /usr/share/emacs/25.0.90/lisp/org/org-macro
/home/beischer/.emacs.d/elpa/org-20160201/org-docview hides /usr/share/emacs/25.0.90/lisp/org/org-docview
/home/beischer/.emacs.d/elpa/org-20160201/org-bbdb hides /usr/share/emacs/25.0.90/lisp/org/org-bbdb
/home/beischer/.emacs.d/elpa/org-20160201/org-footnote hides /usr/share/emacs/25.0.90/lisp/org/org-footnote
/home/beischer/.emacs.d/elpa/org-20160201/ob-picolisp hides /usr/share/emacs/25.0.90/lisp/org/ob-picolisp
/home/beischer/.emacs.d/elpa/org-20160201/org-attach hides /usr/share/emacs/25.0.90/lisp/org/org-attach
/home/beischer/.emacs.d/elpa/org-20160201/ox-latex hides /usr/share/emacs/25.0.90/lisp/org/ox-latex
/home/beischer/.emacs.d/elpa/org-20160201/org-protocol hides /usr/share/emacs/25.0.90/lisp/org/org-protocol
/home/beischer/.emacs.d/elpa/org-20160201/ob-screen hides /usr/share/emacs/25.0.90/lisp/org/ob-screen
/home/beischer/.emacs.d/elpa/org-20160201/org-inlinetask hides /usr/share/emacs/25.0.90/lisp/org/org-inlinetask
/home/beischer/.emacs.d/elpa/org-20160201/org-loaddefs hides /usr/share/emacs/25.0.90/lisp/org/org-loaddefs
/home/beischer/.emacs.d/elpa/org-20160201/org-datetree hides /usr/share/emacs/25.0.90/lisp/org/org-datetree
/home/beischer/.emacs.d/elpa/org-20160201/ob-sql hides /usr/share/emacs/25.0.90/lisp/org/ob-sql
/home/beischer/.emacs.d/elpa/org-20160201/ob hides /usr/share/emacs/25.0.90/lisp/org/ob
/home/beischer/.emacs.d/elpa/org-20160201/org-mobile hides /usr/share/emacs/25.0.90/lisp/org/org-mobile
/home/beischer/.emacs.d/elpa/org-20160201/ox-odt hides /usr/share/emacs/25.0.90/lisp/org/ox-odt
/home/beischer/.emacs.d/elpa/org-20160201/org-pcomplete hides /usr/share/emacs/25.0.90/lisp/org/org-pcomplete
/home/beischer/.emacs.d/elpa/org-20160201/ob-makefile hides /usr/share/emacs/25.0.90/lisp/org/ob-makefile
/home/beischer/.emacs.d/elpa/org-20160201/ob-matlab hides /usr/share/emacs/25.0.90/lisp/org/ob-matlab
/home/beischer/.emacs.d/elpa/org-20160201/ob-ocaml hides /usr/share/emacs/25.0.90/lisp/org/ob-ocaml
/home/beischer/.emacs.d/elpa/org-20160201/ob-java hides /usr/share/emacs/25.0.90/lisp/org/ob-java
/home/beischer/.emacs.d/elpa/org-20160201/org-compat hides /usr/share/emacs/25.0.90/lisp/org/org-compat
/home/beischer/.emacs.d/elpa/org-20160201/org-crypt hides /usr/share/emacs/25.0.90/lisp/org/org-crypt
/home/beischer/.emacs.d/elpa/org-20160201/ox-texinfo hides /usr/share/emacs/25.0.90/lisp/org/ox-texinfo
/home/beischer/.emacs.d/elpa/org-20160201/ox-man hides /usr/share/emacs/25.0.90/lisp/org/ox-man
/home/beischer/.emacs.d/elpa/org-20160201/ob-tangle hides /usr/share/emacs/25.0.90/lisp/org/ob-tangle
/home/beischer/.emacs.d/elpa/org-20160201/ob-dot hides /usr/share/emacs/25.0.90/lisp/org/ob-dot
/home/beischer/.emacs.d/elpa/org-20160201/ob-ref hides /usr/share/emacs/25.0.90/lisp/org/ob-ref
/home/beischer/.emacs.d/elpa/org-20160201/org-entities hides /usr/share/emacs/25.0.90/lisp/org/org-entities
/home/beischer/.emacs.d/elpa/org-20160201/ob-ditaa hides /usr/share/emacs/25.0.90/lisp/org/ob-ditaa
/home/beischer/.emacs.d/elpa/org-20160201/org-gnus hides /usr/share/emacs/25.0.90/lisp/org/org-gnus
/home/beischer/.emacs.d/elpa/org-20160201/org-indent hides /usr/share/emacs/25.0.90/lisp/org/org-indent
/home/beischer/.emacs.d/elpa/org-20160201/ob-R hides /usr/share/emacs/25.0.90/lisp/org/ob-R
/home/beischer/.emacs.d/elpa/org-20160201/ob-lilypond hides /usr/share/emacs/25.0.90/lisp/org/ob-lilypond
/home/beischer/.emacs.d/elpa/org-20160201/ob-css hides /usr/share/emacs/25.0.90/lisp/org/ob-css
/home/beischer/.emacs.d/elpa/org-20160201/ob-mscgen hides /usr/share/emacs/25.0.90/lisp/org/ob-mscgen
/home/beischer/.emacs.d/elpa/org-20160201/ox-md hides /usr/share/emacs/25.0.90/lisp/org/ox-md
/home/beischer/.emacs.d/elpa/org-20160201/org-mouse hides /usr/share/emacs/25.0.90/lisp/org/org-mouse
/home/beischer/.emacs.d/elpa/org-20160201/org-install hides /usr/share/emacs/25.0.90/lisp/org/org-install
/home/beischer/.emacs.d/elpa/org-20160201/ob-table hides /usr/share/emacs/25.0.90/lisp/org/ob-table
/home/beischer/.emacs.d/elpa/org-20160201/ob-latex hides /usr/share/emacs/25.0.90/lisp/org/ob-latex
/home/beischer/.emacs.d/elpa/org-20160201/ob-python hides /usr/share/emacs/25.0.90/lisp/org/ob-python
/home/beischer/.emacs.d/elpa/org-20160201/ob-js hides /usr/share/emacs/25.0.90/lisp/org/ob-js
/home/beischer/.emacs.d/elpa/org-20160201/org-faces hides /usr/share/emacs/25.0.90/lisp/org/org-faces
/home/beischer/.emacs.d/elpa/org-20160201/ob-lob hides /usr/share/emacs/25.0.90/lisp/org/ob-lob
/home/beischer/.emacs.d/elpa/org-20160201/ob-plantuml hides /usr/share/emacs/25.0.90/lisp/org/ob-plantuml
/home/beischer/.emacs.d/elpa/org-20160201/ob-sqlite hides /usr/share/emacs/25.0.90/lisp/org/ob-sqlite
/home/beischer/.emacs.d/elpa/org-20160201/ob-octave hides /usr/share/emacs/25.0.90/lisp/org/ob-octave
/home/beischer/.emacs.d/elpa/org-20160201/org-archive hides /usr/share/emacs/25.0.90/lisp/org/org-archive
/home/beischer/.emacs.d/elpa/org-20160201/ob-lisp hides /usr/share/emacs/25.0.90/lisp/org/ob-lisp
/home/beischer/.emacs.d/elpa/org-20160201/ob-C hides /usr/share/emacs/25.0.90/lisp/org/ob-C
/home/beischer/.emacs.d/elpa/org-20160201/org-agenda hides /usr/share/emacs/25.0.90/lisp/org/org-agenda
/home/beischer/.emacs.d/elpa/org-20160201/org-list hides /usr/share/emacs/25.0.90/lisp/org/org-list
/home/beischer/.emacs.d/elpa/org-20160201/org-irc hides /usr/share/emacs/25.0.90/lisp/org/org-irc
/home/beischer/.emacs.d/elpa/org-20160201/ob-haskell hides /usr/share/emacs/25.0.90/lisp/org/ob-haskell
/home/beischer/.emacs.d/elpa/org-20160201/org-timer hides /usr/share/emacs/25.0.90/lisp/org/org-timer
/home/beischer/.emacs.d/elpa/org-20160201/org-plot hides /usr/share/emacs/25.0.90/lisp/org/org-plot
/home/beischer/.emacs.d/elpa/org-20160201/org-habit hides /usr/share/emacs/25.0.90/lisp/org/org-habit
/home/beischer/.emacs.d/elpa/org-20160201/ob-core hides /usr/share/emacs/25.0.90/lisp/org/ob-core
/home/beischer/.emacs.d/elpa/org-20160201/ob-comint hides /usr/share/emacs/25.0.90/lisp/org/ob-comint
/home/beischer/.emacs.d/elpa/org-20160201/ox-beamer hides /usr/share/emacs/25.0.90/lisp/org/ox-beamer
/home/beischer/.emacs.d/elpa/org-20160201/org-colview hides /usr/share/emacs/25.0.90/lisp/org/org-colview
/home/beischer/.emacs.d/elpa/org-20160201/ob-shen hides /usr/share/emacs/25.0.90/lisp/org/ob-shen
/home/beischer/.emacs.d/elpa/org-20160201/org-macs hides /usr/share/emacs/25.0.90/lisp/org/org-macs
/home/beischer/.emacs.d/elpa/org-20160201/ox-publish hides /usr/share/emacs/25.0.90/lisp/org/ox-publish
/home/beischer/.emacs.d/elpa/org-20160201/ox-ascii hides /usr/share/emacs/25.0.90/lisp/org/ox-ascii
/home/beischer/.emacs.d/elpa/org-20160201/ob-calc hides /usr/share/emacs/25.0.90/lisp/org/ob-calc
/home/beischer/.emacs.d/elpa/org-20160201/org-eshell hides /usr/share/emacs/25.0.90/lisp/org/org-eshell
/home/beischer/.emacs.d/elpa/org-20160201/ob-asymptote hides /usr/share/emacs/25.0.90/lisp/org/ob-asymptote
/home/beischer/.emacs.d/elpa/org-20160201/org-clock hides /usr/share/emacs/25.0.90/lisp/org/org-clock
/home/beischer/.emacs.d/elpa/org-20160201/ob-emacs-lisp hides /usr/share/emacs/25.0.90/lisp/org/ob-emacs-lisp
/home/beischer/.emacs.d/elpa/org-20160201/ob-clojure hides /usr/share/emacs/25.0.90/lisp/org/ob-clojure
/home/beischer/.emacs.d/elpa/org-20160201/org hides /usr/share/emacs/25.0.90/lisp/org/org
/home/beischer/.emacs.d/elpa/org-20160201/ob-org hides /usr/share/emacs/25.0.90/lisp/org/ob-org
/home/beischer/.emacs.d/elpa/org-20160201/ox hides /usr/share/emacs/25.0.90/lisp/org/ox
/home/beischer/.emacs.d/elpa/org-20160201/org-info hides /usr/share/emacs/25.0.90/lisp/org/org-info
/home/beischer/.emacs.d/elpa/org-20160201/ox-org hides /usr/share/emacs/25.0.90/lisp/org/ox-org
/home/beischer/.emacs.d/elpa/org-20160201/ob-maxima hides /usr/share/emacs/25.0.90/lisp/org/ob-maxima
/home/beischer/.emacs.d/elpa/org-20160201/org-version hides /usr/share/emacs/25.0.90/lisp/org/org-version
/home/beischer/.emacs.d/elpa/emms-20160207.420/tq hides /usr/share/emacs/25.0.90/lisp/emacs-lisp/tq
Features:
(shadow mail-extr emacsbug sendmail semantic/tag-file whitespace
cap-words superword subword ggtags ewoc semantic/db-file data-debug
cedet-files function-args semantic-directory semantic/ia character-fold
misearch multi-isearch jka-compr company-oddmuse company-keywords
company-etags company-gtags company-dabbrev-code company-dabbrev
company-files company-capf company-cmake company-xcode company-clang
company-semantic company-eclim company-template company-css company-nxml
company-bbdb company-edbi edbi sql view jedi jedi-core
python-environment epc ctable concurrent deferred auto-complete popup
cmake-project gist gh-gist gh-oauth gh-api logito gh-cache pcache
gh-auth gh-common gh-url eieio-compat url-http tls gnutls url-auth
url-gw gh-profile json map timezone emms-librefm-stream xml
emms-librefm-scrobbler emms-playlist-limit emms-volume
emms-volume-amixer emms-i18n emms-history emms-score emms-stream-info
emms-metaplaylist-mode emms-bookmarks emms-mode-line-icon
emms-player-xine emms-info-ogginfo emms-player-vlc emms-player-mplayer
emms-player-mpd tq emms-tag-editor emms-mark emms-info-mp3info
emms-mode-line emms-info-metaflac emms-cue emms-playing-time
emms-streams emms-browser sort emms-playlist-sort emms-playlist-mode
emms-source-playlist emms-last-played emms-cache emms-info later-do
emms-lyrics emms-url emms-source-file locate emms-player-simple
emms-setup emms emms-compat org-install tempo url url-proxy url-privacy
url-expand url-methods url-history url-cookie url-domsuf url-util
url-parse url-vars mailcap xml-parse doxymacs projectile ibuf-ext
ibuffer dropdown-list yasnippet cl my-term term disp-table ehelp f s
etags-table etags xref project cmake-mode thingatpt rx qt-pro pastebin
window-numbering company magit-topgit magit-blame magit-stash
magit-bisect magit-remote magit-commit magit-sequence magit esh-var
esh-io esh-cmd esh-opt esh-ext esh-proc esh-arg esh-groups eshell
esh-module esh-mode esh-util magit-apply magit-wip magit-log magit-diff
smerge-mode diff-mode magit-core magit-autorevert autorevert filenotify
magit-process magit-popup magit-mode derived magit-git crm magit-section
magit-utils git-commit recentf tree-widget log-edit easy-mmode message
idna rfc822 mml mml-sec epg mm-decode mm-bodies mm-encode mail-parse
rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev mail-utils gmm-utils
mailheader pcvs-util add-log with-editor async-bytecomp async tramp-sh
server dash hide-lines buff-menu+ hideshow flx-ido flx ido seq dired-x
dired srecode/mode semantic/senator semantic/wisent
semantic/wisent/wisent srecode/insert srecode/filters srecode/args
srecode/find srecode/map srecode/ctxt srecode/compile srecode/dictionary
srecode/table semantic/db-mode srecode semantic/bovine/c hideif
semantic/bovine/c-by semantic/lex-spp semantic/idle semantic/bovine/gcc
semantic/dep semantic/bovine semantic/analyze/refs semantic/analyze
semantic/sort semantic/scope semantic/analyze/fcn semantic/ctxt
semantic/format semantic/decorate/include semantic/db-find
semantic/db-ref semantic/db semantic/decorate/mode semantic/tag-ls
semantic/find semantic/decorate pulse semantic/util-modes semantic/util
semantic semantic/tag semantic/lex semantic/fw mode-local find-func
ede/speedbar ede/files ede ede/detect ede/base ede/auto ede/source
eieio-base eieio-speedbar speedbar sb-image ezimage dframe eieio-custom
wid-edit cedet cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles
cc-align cc-engine cc-vars cc-defs flymake finder-inf
ack-and-a-half-autoloads tex-site dropdown-list-autoloads
etags-table-autoloads helm-git-autoloads helm-git-grep-autoloads
jira-autoloads logito-autoloads pastebin-autoloads pymacs-autoloads
pysmell-autoloads syslog-mode-autoloads info package epg-config vc-cvs
tramp tramp-compat auth-source cl-seq eieio byte-opt bytecomp
byte-compile cl-extra cconv eieio-core cl-macs gv gnus-util mm-util
help-fns help-mode easymenu mail-prsvr password-cache tramp-loaddefs
trampver ucs-normalize shell pcomplete format-spec advice edmacro kmacro
cl-loaddefs pcase cl-lib emacs-x-theme paren grep compile comint
ansi-color ring linum hi-lock cus-start cus-load time-date mule-util
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type
mwheel x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt
fringe tabulated-list newcomment elisp-mode lisp-mode prog-mode register
page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock
font-lock syntax facemenu font-core frame cl-generic cham georgian
utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese charscript case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice
loaddefs button faces cus-face macroexp files text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote dbusbind inotify dynamic-setting
system-font-setting font-render-setting move-toolbar gtk x-toolkit x
multi-tty make-network-process emacs)
Memory information:
((conses 16 671947 27404)
(symbols 48 53448 2)
(miscs 40 246 548)
(strings 32 146657 25021)
(string-bytes 1 4093934)
(vectors 16 78402)
(vector-slots 8 1403481 16512)
(floats 8 1680 128)
(intervals 56 2241 6432)
(buffers 976 16)
(heap 1024 61004 6597))
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-07 20:41 bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol Bastian Beischer
@ 2016-02-08 0:09 ` Bastian Beischer
2016-02-08 0:54 ` Juri Linkov
1 sibling, 0 replies; 12+ messages in thread
From: Bastian Beischer @ 2016-02-08 0:09 UTC (permalink / raw)
To: 22589
[-- Attachment #1: Type: text/plain, Size: 393 bytes --]
The same bug also exists in isearch-forward-word.
--
Bastian Beischer
RWTH Aachen University of Technology
@RWTH Aachen
Office: 28 C 203
Phone: +49-241-80-27205
E-mail: beischer@physik.rwth-aachen.de
Address: I. Physikalisches Institut B, Sommerfeldstr. 14, D-52074 Aachen
@CERN
Office: Bdg 32-4-B12
Phone: +41-22-76-75750
E-mail: bastian.beischer@cern.ch
Address: CERN, CH-1211 Geneve 23
[-- Attachment #2: Type: text/html, Size: 653 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-07 20:41 bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol Bastian Beischer
2016-02-08 0:09 ` Bastian Beischer
@ 2016-02-08 0:54 ` Juri Linkov
2016-02-08 11:30 ` Michael Heerdegen
2016-02-08 11:34 ` Bastian Beischer
1 sibling, 2 replies; 12+ messages in thread
From: Juri Linkov @ 2016-02-08 0:54 UTC (permalink / raw)
To: Bastian Beischer; +Cc: 22589
> Instructions to reproduce:
>
> 1) emacs -Q
> 2) open a new file called "test.c"
> 3) enter this text:
>
> int main() {
> int i = 0;
> return 0;
> }
>
> 4) go to the beginning of the buffer
> 5) hit M-s _ and search for the symbol "i"
>
> ---> The very first character in "int main" is highlighted as a match
> even though the first match should be "i" in "int i =0".
Please imagine that you need to search for the symbol "int"
(or any other symbol longer than the single-character "i").
How then you would be able to type the whole symbol "int"
if the search failed after typing the first character "i"
(or moved to the first occurrence of the symbol "i"
when you need to find the symbol "int")?
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-08 0:54 ` Juri Linkov
@ 2016-02-08 11:30 ` Michael Heerdegen
2016-02-10 0:55 ` Juri Linkov
2016-02-08 11:34 ` Bastian Beischer
1 sibling, 1 reply; 12+ messages in thread
From: Michael Heerdegen @ 2016-02-08 11:30 UTC (permalink / raw)
To: Juri Linkov; +Cc: Bastian Beischer, 22589
Juri Linkov <juri@linkov.net> writes:
> Please imagine that you need to search for the symbol "int" (or any
> other symbol longer than the single-character "i"). How then you
> would be able to type the whole symbol "int" if the search failed
> after typing the first character "i" (or moved to the first occurrence
> of the symbol "i" when you need to find the symbol "int")?
I agree that this is a useful feature. Not having it would make
entering the search pattern confusing.
But I think it should be documented. When does it occur, and what else
is matched (one or two sentences).
There could also be some indication when this first match is not a
"real" match - but that might be overkill.
Regards,
Michael.
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-08 0:54 ` Juri Linkov
2016-02-08 11:30 ` Michael Heerdegen
@ 2016-02-08 11:34 ` Bastian Beischer
2016-02-10 0:54 ` Juri Linkov
1 sibling, 1 reply; 12+ messages in thread
From: Bastian Beischer @ 2016-02-08 11:34 UTC (permalink / raw)
To: Juri Linkov; +Cc: 22589
[-- Attachment #1: Type: text/plain, Size: 1716 bytes --]
Hello Juri,
On Mon, Feb 8, 2016 at 1:54 AM, Juri Linkov <juri@linkov.net> wrote:
> > Instructions to reproduce:
> >
> > 1) emacs -Q
> > 2) open a new file called "test.c"
> > 3) enter this text:
> >
> > int main() {
> > int i = 0;
> > return 0;
> > }
> >
> > 4) go to the beginning of the buffer
> > 5) hit M-s _ and search for the symbol "i"
> >
> > ---> The very first character in "int main" is highlighted as a match
> > even though the first match should be "i" in "int i =0".
>
> Please imagine that you need to search for the symbol "int"
> (or any other symbol longer than the single-character "i").
> How then you would be able to type the whole symbol "int"
> if the search failed after typing the first character "i"
> (or moved to the first occurrence of the symbol "i"
> when you need to find the symbol "int")?
>
What you are saying makes sense, but the bug I outlined above is more
severe.
For example: In this line:
unsigned int i = 0;
when searching for the symbol "i". Taking your comment into account I can
see why the first match would be "int", although that's actually not a
match for "\_<i\_>", because if we would match "i" directly, then there
would be no way to go back to match "int" should the user enter more
characters. However, what happens is that the "i" in unsIgned is matched,
which is surely never going to be a symbol...
--
Bastian Beischer
RWTH Aachen University of Technology
@CERN
Office: Bdg 32-4-B12
Phone: +41-22-76-75750
E-mail: bastian.beischer@cern.ch
Address: CERN, CH-1211 Geneve 23
@RWTH Aachen
Office: 28 C 203
Phone: +49-241-80-27205
E-mail: beischer@physik.rwth-aachen.de
Address: I. Physikalisches Institut B, Sommerfeldstr. 14, D-52074 Aachen
[-- Attachment #2: Type: text/html, Size: 2755 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-08 11:34 ` Bastian Beischer
@ 2016-02-10 0:54 ` Juri Linkov
2017-02-05 23:39 ` Juri Linkov
0 siblings, 1 reply; 12+ messages in thread
From: Juri Linkov @ 2016-02-10 0:54 UTC (permalink / raw)
To: Bastian Beischer; +Cc: 22589
> What you are saying makes sense, but the bug I outlined above is more
> severe.
>
> For example: In this line:
>
> unsigned int i = 0;
>
> when searching for the symbol "i". Taking your comment into account I can
> see why the first match would be "int", although that's actually not a
> match for "\_<i\_>", because if we would match "i" directly, then there
> would be no way to go back to match "int" should the user enter more
> characters. However, what happens is that the "i" in unsIgned is matched,
> which is surely never going to be a symbol...
Thank you for the detailed test case. The reason why “i” matches
in the middle of the symbol by not adding an anchor “\_<” is because
we need to support the symbol search backwards as well. This means
that the symbol search should add “\_<” for searching forward,
and “\_>” for a backward search. The same applies to the word search.
We could do this by adding an optional argument ‘backward’ to both
‘word-search-regexp’ and ‘isearch-symbol-regexp’. One complication is that
this change is not backward-compatible. Instead of this, I propose to use
different values of the existing arg ‘lax’, e.g. values ‘nil’
for a forward search, and ‘backward’ otherwise.
Then it will match at the beginning of the symbol for a forward search,
and at the end for a backward search. Same for the word search.
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-08 11:30 ` Michael Heerdegen
@ 2016-02-10 0:55 ` Juri Linkov
2016-02-10 11:30 ` Michael Heerdegen
0 siblings, 1 reply; 12+ messages in thread
From: Juri Linkov @ 2016-02-10 0:55 UTC (permalink / raw)
To: Michael Heerdegen; +Cc: Bastian Beischer, 22589
> I agree that this is a useful feature. Not having it would make
> entering the search pattern confusing.
>
> But I think it should be documented. When does it occur, and what else
> is matched (one or two sentences).
>
> There could also be some indication when this first match is not a
> "real" match - but that might be overkill.
Then we could use the already existing indication "[pending]"
in the search prompt.
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-10 0:55 ` Juri Linkov
@ 2016-02-10 11:30 ` Michael Heerdegen
0 siblings, 0 replies; 12+ messages in thread
From: Michael Heerdegen @ 2016-02-10 11:30 UTC (permalink / raw)
To: Juri Linkov; +Cc: Bastian Beischer, 22589
Juri Linkov <juri@linkov.net> writes:
> > I agree that this is a useful feature. Not having it would make
> > entering the search pattern confusing.
> >
> > But I think it should be documented. When does it occur, and what else
> > is matched (one or two sentences).
> >
> > There could also be some indication when this first match is not a
> > "real" match - but that might be overkill.
>
> Then we could use the already existing indication "[pending]"
> in the search prompt.
I think that would be a good solution.
Michael.
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2016-02-10 0:54 ` Juri Linkov
@ 2017-02-05 23:39 ` Juri Linkov
2017-02-06 11:10 ` Michael Heerdegen
0 siblings, 1 reply; 12+ messages in thread
From: Juri Linkov @ 2017-02-05 23:39 UTC (permalink / raw)
To: Bastian Beischer; +Cc: 22589
> Then it will match at the beginning of the symbol for a forward search,
> and at the end for a backward search. Same for the word search.
In bug#25562 we found no more ideas how to improve the support for
the process of entering incomplete words, so in addition to the patch
in bug#25562 that adds indication, also I'm going to install this patch
that will optimize the incomplete search by removing conditional
matching at the beginning:
diff --git a/lisp/isearch.el b/lisp/isearch.el
index 5c48c30..90ffbec 100644
--- a/lisp/isearch.el
+++ b/lisp/isearch.el
@@ -1621,7 +1621,7 @@ (defun word-search-regexp (string &optional lax)
((string-match-p "\\`\\W+\\'" string) "\\W+")
(t (concat
(if (string-match-p "\\`\\W" string) "\\W+"
- (unless lax "\\<"))
+ "\\<")
(mapconcat 'regexp-quote (split-string string "\\W+" t) "\\W+")
(if (string-match-p "\\W\\'" string) "\\W+"
(unless lax "\\>"))))))
@@ -1749,7 +1749,7 @@ (defun isearch-symbol-regexp (string &optional lax)
((string-match-p (format "\\`%s\\'" not-word-symbol-re) string) not-word-symbol-re)
(t (concat
(if (string-match-p (format "\\`%s" not-word-symbol-re) string) not-word-symbol-re
- (unless lax "\\_<"))
+ "\\_<")
(mapconcat 'regexp-quote (split-string string not-word-symbol-re t) not-word-symbol-re)
(if (string-match-p (format "%s\\'" not-word-symbol-re) string) not-word-symbol-re
(unless lax "\\_>")))))))
^ permalink raw reply related [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2017-02-05 23:39 ` Juri Linkov
@ 2017-02-06 11:10 ` Michael Heerdegen
2017-02-07 0:11 ` Juri Linkov
0 siblings, 1 reply; 12+ messages in thread
From: Michael Heerdegen @ 2017-02-06 11:10 UTC (permalink / raw)
To: Juri Linkov; +Cc: Bastian Beischer, 22589
Juri Linkov <juri@linkov.net> writes:
> > Then it will match at the beginning of the symbol for a forward search,
> > and at the end for a backward search. Same for the word search.
>
> In bug#25562 we found no more ideas how to improve the support for
> the process of entering incomplete words, so in addition to the patch
> in bug#25562 that adds indication, also I'm going to install this patch
> that will optimize the incomplete search by removing conditional
> matching at the beginning:
I think I prefer the original behavior (but actually, I use a private
version of `word-search-regexp' that behaves entirely differently, so my
opinion doesn't matter). But apart from that, the patch doesn't work as
expected (even with the other patch that adds indication also
installed):
- in emacs -Q, hit C-h i to go to the info top dir
- I want to word search for "directory". point is at point-min.
- I hit d. Isearch jumps to the "d" in "Type "d" in Info to..."
- I type the remaining letters: "irectory". The isearch prompt says
"Failed" apparently because I'm now past all matches and isearch
didn't reconsider the text before the first match "d".
Michael.
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2017-02-06 11:10 ` Michael Heerdegen
@ 2017-02-07 0:11 ` Juri Linkov
2017-02-07 19:19 ` Michael Heerdegen
0 siblings, 1 reply; 12+ messages in thread
From: Juri Linkov @ 2017-02-07 0:11 UTC (permalink / raw)
To: Michael Heerdegen; +Cc: 22589
>> In bug#25562 we found no more ideas how to improve the support for
>> the process of entering incomplete words, so in addition to the patch
>> in bug#25562 that adds indication, also I'm going to install this patch
>> that will optimize the incomplete search by removing conditional
>> matching at the beginning:
>
> I think I prefer the original behavior (but actually, I use a private
> version of `word-search-regexp' that behaves entirely differently, so my
> opinion doesn't matter). But apart from that, the patch doesn't work as
> expected (even with the other patch that adds indication also
> installed):
>
> - in emacs -Q, hit C-h i to go to the info top dir
>
> - I want to word search for "directory". point is at point-min.
>
> - I hit d. Isearch jumps to the "d" in "Type "d" in Info to..."
>
> - I type the remaining letters: "irectory". The isearch prompt says
> "Failed" apparently because I'm now past all matches and isearch
> didn't reconsider the text before the first match "d".
Hmm, this is strange. Unlike the more radical patch in
https://debbugs.gnu.org/25562#22, the latest patch here in
https://debbugs.gnu.org/22589#31 is more moderate - it just restricts
matches to word beginnings, so your recipe didn't fail when I tried.
^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol.
2017-02-07 0:11 ` Juri Linkov
@ 2017-02-07 19:19 ` Michael Heerdegen
0 siblings, 0 replies; 12+ messages in thread
From: Michael Heerdegen @ 2017-02-07 19:19 UTC (permalink / raw)
To: Juri Linkov; +Cc: 22589
Juri Linkov <juri@linkov.net> writes:
> Hmm, this is strange. Unlike the more radical patch in
> https://debbugs.gnu.org/25562#22, the latest patch here in
> https://debbugs.gnu.org/22589#31 is more moderate - it just restricts
> matches to word beginnings, so your recipe didn't fail when I tried.
My fault indeed. Because the patch didn't apply with any Emacs tool, I
had applied it "by hand", but that in a wrong way.
Looks ok now after just calling "patch", and the behavior also seems to
make sense. Sorry about the confusion.
Michael.
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2017-02-07 19:19 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-07 20:41 bug#22589: 25.0.90; First match found by isearch-forward-symbol is not necessarily a symbol Bastian Beischer
2016-02-08 0:09 ` Bastian Beischer
2016-02-08 0:54 ` Juri Linkov
2016-02-08 11:30 ` Michael Heerdegen
2016-02-10 0:55 ` Juri Linkov
2016-02-10 11:30 ` Michael Heerdegen
2016-02-08 11:34 ` Bastian Beischer
2016-02-10 0:54 ` Juri Linkov
2017-02-05 23:39 ` Juri Linkov
2017-02-06 11:10 ` Michael Heerdegen
2017-02-07 0:11 ` Juri Linkov
2017-02-07 19:19 ` Michael Heerdegen
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).