I am seeing the same thing. Consider the following simple C++ example:
// on mouse hover VA Refactoring Context Menu is offered on "void" "short" and "else" in this function
// it is Not offered on "if" - even though Modify Expression is offered on "if", and makes sense
// VA is offering Find References and Rename on "void", "short" and "else"
short testRefactoringContextMenuKeywords()
{
short nShortOne = 1;
short nShortTwo = 2;
if (nShortOne < nShortTwo)
{
nShortOne++;
}
// refactoring context menu offering Modify Expression on "else" makes sense
// but Find References and Rename on "else" don't make sense
else if (nShortOne == nShortTwo)
{
nShortOne++;
}
else
{
nShortTwo++;
}
// on mouse hover also offered on "return", but several of the options make sense
return nShortOne;
}
simply not offering the hovering context menu on keywords isn't actually the solution here. Arguably it should be offered on "if", but it doesn't make any sense to offer Rename, or really Find References on keywords.
But if you have a macro for a keyword, then offering rename on that is probably reasonable.
So the question becomes, where to draw the line? My first thought is to say that Rename and Find References just don't make sense on keywords, but if anything else is being offered then it is reasonable to offer the context menu on mouse hover. Does this seem reasonable?
But having said that, is there ever a time when you would want to run Find References on a keyword? Renaming a keyword just seems really unwise, but finding all references to "virtual" in the current file, for example, might be helpful.