Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Technical Support
 Frustrating auto-replace bug
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

znakeeye
Tomato Guru

379 Posts

Posted - Feb 18 2010 :  04:43:48 AM  Show Profile  Reply with Quote
VAX 1738 (and all versions I can remember), VS 2008 SP1.

Consider this:
enum MyType { myType1, myType2 };

Then I want to use a MyType variable that does NOT exist - yet:

void foo()
{
    bar(myType); // Suggestion list not used!
}
"myType" is replaced with "MyType" by VAX.

I run into this all the time! I know VAX tries to do the best in this situation, but since I TYPE the whole variable name, VAX should NOT replace it!

feline
Whole Tomato Software

United Kingdom
19021 Posts

Posted - Feb 18 2010 :  10:58:54 AM  Show Profile  Reply with Quote
If you have:

VA Options -> Advanced -> Correction -> Repair case

turned On then this is by design. Turning off this option stops this from happening.

http://www.wholetomato.com/products/features/case.asp

VA has no way of knowing you are typing an unknown symbol, and typing a known symbol with the wrong case is a common situation.

zen is the art of being at one with the two'ness
Go to Top of Page

kevinsikes
Tomato Guru

USA
271 Posts

Posted - Feb 18 2010 :  10:49:43 PM  Show Profile  Reply with Quote
This would be a good use case for Create from Usage. After typing the variable name, invoke the refactoring menu via mouse hover or keystroke (Alt+Shift+Q is the default beginning with VA X 1810, but you can bind your own keystroke to VAssistX.RefactorContextMenu). Choose "Create variable myType" and give it the type MyType.



If you don't want to perform a Create from Usage on the unknown myType symbol, then a simple undo keystroke will revert MyType to myType; there is no need to manually re-type the name. Or you could do as Feline suggests, and turn off the Repair Case feature.

Kevin Sikes
Infotainment Platform Design Engineer
Ford Motor Company
Go to Top of Page

znakeeye
Tomato Guru

379 Posts

Posted - Feb 19 2010 :  09:05:36 AM  Show Profile  Reply with Quote
Repair Case in MS Word/Office etc is undone when pressing Ctrl+Z. You should have that feature too.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19021 Posts

Posted - Feb 19 2010 :  10:54:07 AM  Show Profile  Reply with Quote
The IDE undo command is undoing Repair case for me, in VS2005 and VS2008 with both VA 1812 and VA 1738.

zen is the art of being at one with the two'ness
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000