From: Dmitry Gutov <dgutov@yandex.ru> Date: Sun, 10 May 2015 17:43:54 +0000 (+0300) Subject: semantic/symref/grep: Don't use word boundaries X-Git-Tag: emacs-25.0.90~2130 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=ec13f4b344fc8f840647209137e29be470143969;p=emacs.git semantic/symref/grep: Don't use word boundaries * lisp/cedet/semantic/symref/grep.el (semantic-symref-perform-search): Instead of wrapping input in word boundaries, check that the characters before and after are not word constituents. --- diff --git a/lisp/cedet/semantic/symref/grep.el b/lisp/cedet/semantic/symref/grep.el index 3cf841e4f2c..6325eb4a396 100644 --- a/lisp/cedet/semantic/symref/grep.el +++ b/lisp/cedet/semantic/symref/grep.el @@ -158,7 +158,11 @@ This shell should support pipe redirect syntax." (cond ((eq (oref tool :searchtype) 'regexp) (oref tool searchfor)) (t - (concat "\\<" (oref tool searchfor) "\\>"))))) + ;; Can't use the word boundaries: Grep + ;; doesn't always agrees with the language + ;; syntax on those. + (format "\\(^\\|\\W\\)%s\\(\\W\\|$\\)" + (oref tool searchfor)))))) ;; Misc (b (get-buffer-create "*Semantic SymRef*")) (ans nil)