On Nov 17, 2006, at 1:05 PM, Vadim Bendebury wrote:
Say I want to search for other occurences of a word which the cursor is ot. I hit C-s C-w C-s and off it goes. The problem is when the word includes underscores - each C-w moves the mark to the next underscore, nit to the end ofthe word. Is there a way to configure emacs such that underscore is considered part of the word?
I do this for C mode: (modify-syntax-entry 95 "w" c-mode-syntax-table)
Two problems:
1) There are comments somewhere that explicitly say "don't do this!!!" but I never figured out why. I'd like to here from others why this is not recommended.
2) There are lots of syntax tables. Most major-modes have their own. Some minor-modes I think diddle with them too. Plus there is a global syntax table. So, you will need to explore and figure out which syntax tables you want to change. Then add the modification to the appropriate hook(s).
I have this in my .emacs file:
(custom-set-variables
...
'(c-initialization-hook (function (lambda nil (modify-syntax-entry 95 "w" c-mode-syntax-table))))
... )
Low cost SATA Disk Systems for IBMs p5, pSeries, and RS/6000 AIX systems