Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 go to symbol definition more immediately useful...

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

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

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 - Feb 12 2014 : 09:13:34 AM
void myfun()
using MyNamespace::MyClass;

... code ...

MyClass f(arg1, ...);

When I use "go to definition of MyClass where f is defined, I am shown the first line in the function, the using declaration.

This not so useful.

I want to actually see what I can do with an "MyClass" in order to instantiate it or manipulate it, and for that, I need to to go to the definition of MyClass, not the using deceleration.

Can we have an option (if not always the implicit default) to go to the real definition?

NOTE: The same thing applies for
- such as typedef std::vector<int> intvect; <-- I really don't want to see this line - I want to see the definition of vector so I can see what I can do with it - which is 99.9999% of the time why I want to see the definition of a symbol.

Also note: when looking at a variable - it is not unreasonable to jump first to the declaration of that variable, then have to regress to that type's definition. I Just don't want to go from type to alias for type to actual type. That alias thing is not helpful, IMO.

Lastly: It would be great if there were a key-modifier option to jump straight from the instance variable to the real definition of its ultimate type without having to do that stop-at-declaration phase also, such as "Alt+go to definition" or some such.
11   L A T E S T    R E P L I E S    (Newest First)
Mordachai Posted - Nov 07 2014 : 10:54:49 AM
Woo-hoo! ;D
sean Posted - Nov 07 2014 : 09:51:35 AM
case=80352 is fixed in build 2052.
sean Posted - Sep 19 2014 : 12:34:02 AM
case=82118 is implemented in build 2047
Mordachai Posted - May 23 2014 : 11:21:09 PM
Awesome! can't wait to check it out!
sean Posted - May 23 2014 : 10:05:46 PM
case=82118 has been opened to enhance the goto "type of symbol" introduced as part of "Goto Related" in build 2036.
sean Posted - Apr 07 2014 : 3:31:14 PM
case=80380 is fixed in build 2031
Mordachai Posted - Feb 26 2014 : 10:08:34 AM
Thanks for clarifying and finding the additional bug. :)
accord Posted - Feb 21 2014 : 1:18:43 PM
Since you are already over the declaration of pItem, alt+g won't take you anywhere. If you move the caret over auto (which is just a "disguise" for a type) alt+g should take you to the correct place.

I created a little code sample to demonstrate this:

As you can see, the caret is over "auto", and it's recognised as TestClass, and alt+g take me there.

However, if I use a typedef for the vector, it won't work anymore. I have put in a bug report for that:


but there isn't any way to jump to the code for a CDynamicMenuItem except of course to trick the system by typing that string in directly

Find symbol in dialog (alt+shift+s) might be easier a little bit until this gets fixed.
Mordachai Posted - Feb 21 2014 : 10:30:53 AM
On a related subject:

vector_type_alias items;
for (auto * pItem : items)

If I try to "go to" pItem - I can see the definition in the "go" drop down at the top of the edit view - but I can't actually go anywhere at all. VA appears to know that pItem is a pointer to a specific type (in my case, a CDynamicMenuItem), but there isn't any way to jump to the code for a CDynamicMenuItem except of course to trick the system by typing that string in directly, and then "going to" that thing.

I should be able to "go to" pItem - and actually get to the underlying type in it's .h file.

Mordachai Posted - Feb 21 2014 : 08:47:00 AM
Great! I hope to see that! :)
accord Posted - Feb 20 2014 : 2:34:21 PM
I was able to reproduce the problem and I have put in a bugreport for alt+g (Goto icon) jumping to using directive:


Regarding typedef: Personally, I'm happy that alt+g jumps to the typedef, since when you're using someone else's code, it is good to know what a symbol is "hiding" from you. intvect is a reasonably good name for this typedef, but I have seen worse, when you can't guess easily. Guessing isn't for programmers anyway :)

But! I like you next idea AND it also kind of solves your typedef problem: a "special" goto could jump to the symbol right away, even with typedefs. We are already considering to implement this idea at some point:


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