My roommate Tor
pointed out to me that Evil Mode doesn't
always consider underscores are part of the word boundary so
incantations like diw
don't behave the way
we expect them. In programming modes, this should be safe:
'prog-mode-hook #'cce/underscore_word_boundaries)
(add-hook defun cce/underscore_word_boundaries ()
("w"))
(modify-syntax-entry ?_ provide 'cce/underscores-syntax-table) (
Note that this adds a hook rather than setting prog-mode-syntax-table
. I observed that
modifying that syntax table didn't achieve what I was looking for in
modes that inherit from it. So be it. Hook City, USA, baby.