#define BITMASK 0x200 if (value & BITMASK) ; value += ~BITMASK;
When I place the mouse on BITMASK in the second line I get a refactoring menu. That is fine.
When I place the mouse on BITMASK in the first line (the #define) I don't get this menu. It is quite annoying to always look for a place where the define is used to rename it. Or even to figure out whether it is used at all without beeing able to use "Find References".
Additionally the refactoring menu doesn't work on the third line, too. The "~" is shown in the same color as the symbol and the Menu says "Refactoring not available on symbol". It seems that the operator is interpreted as part of the symbol.
#define BITMASK 0x200 if (value & BITMASK) ; value += ~BITMASK;
When I place the mouse on BITMASK in the second line I get a refactoring menu. That is fine.
When I place the mouse on BITMASK in the first line (the #define) I don't get this menu. It is quite annoying to always look for a place where the define is used to rename it. Or even to figure out whether it is used at all without beeing able to use "Find References".
Additionally the refactoring menu doesn't work on the third line, too. The "~" is shown in the same color as the symbol and the Menu says "Refactoring not available on symbol". It seems that the operator is interpreted as part of the symbol.
I'm seeing the something similar with build 1647. On the #define and 'if' lines I can rename and find. On the '~' line I only have find. If I put a space between '~' and BITMASK then the rename options comes up.
quote: I'm seeing the something similar with build 1647. On the #define and 'if' lines I can rename and find. On the '~' line I only have find. If I put a space between '~' and BITMASK then the rename options comes up.
Mark
It doesn't work with my build 1647 on VC6 on the #define line. This is my main problem.
Of course the space does help. I would still consider this a bug.
I am seeing both problems, thank you for the clear descriptions. Having to put a space between the ~ and the variable name is:
case=18979
The hovering refactoring menu not appearing where the #define is created is:
case=9622
There are a couple of work arounds for this. Either use VA's Shift + right click menu on the #define, or select BITMASK on this line and then hover the mouse over the selected text. The refactoring context menu is offered when the text is selected.