I am searching some pattern, navigate between search results, and at the same time I want some other pattern to be highlighted. For example, I jump between invocations of some function in my project, usually there is a variable named "session" around and I want this word to be highlighted.
What I do is:
:match StatusLineTerm /session/
StatusLineTerm is just a name of existing highlight group having the color I like.
The question is: how to create some key combination that would call this
match command using the word under cursor as a match pattern? Something like
nnoremap <F5> :match StatusLineTerm /.expand(<cword>)/, but actually working?