Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 report value of external statics

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
Mordachai Posted - Mar 12 2012 : 11:59:18 AM
Commonly, I'll have one .cpp file that defines a given set of statics:

const TCHAR * kDatabaseMinMenuVersion = "11.0";
const TCHAR * kDatabaseMinMacroVersion = "11.0";
const TCHAR * kGeneratedVersionRequired = "11.2";
const TCHAR * kNewGeneratedVersionRequired = "11.2";

And another one or more .cpp files that refer to these statics:

extern const TCHAR * kDatabaseMinMenuVersion;
extern const TCHAR * kDatabaseMinMacroVersion;
extern const TCHAR * kGeneratedVersionRequired;
extern const TCHAR * kNewGeneratedVersionRequired;

I would like VA to telll me that kDatabaseMinMenuVersion is "11.0" when I mouse-hover over it, instead of telling me that it is const TCHAR *, regardless of what .cpp file I am in.

It is already useful in the source .cpp - the file which does the defining of the string. But in the other .cpp files, which use the extern, VA doesn't seem to be able to tell me the real value of the symbol (or is this a function of VS2010?).

At any rate, it would be a really useful feature to me to always see the real static definition of the symbol regardless of which .cpp file I happen to be in (or .h for that matter).
1   L A T E S T    R E P L I E S    (Newest First)
accord Posted - Mar 13 2012 : 8:02:39 PM
Interesting proposal and makes sense. I have put in an enhancement request for you:

case=65315

The interesting part is that Intellisense will not show the correct definition either. (i.e. quick info tooltip and code definition window).
"Workaround" is to use Visual Assist's find references, so you can "peep" the constant's default value, without moving the caret around (sometimes I do this for static variables, where the default value isn't shown either)

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000