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
 Alt-G Goto will not go to source from header
 New Topic  Reply to Topic
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

JanSolo
New Member

Canada
2 Posts

Posted - Jan 06 2012 :  6:15:48 PM  Show Profile  Reply with Quote
Using: VA_X.dll file version 10.6.1850.0 built 2011.06.07

When I use Alt-G on a function name in my project, I'm taken to the definition of that function in its header(.h).
However, when I Alt-G on the definition, I expect to be taken to the body of the function in the source(.cpp) file. This does not work for me.

Alt-G only ever takes me to the header definition, never the source file. It's very annoying.

I searched and problem is almost identical to this one from a few years ago:
http://forum.wholetomato.com/forum/topic.asp?TOPIC_ID=8901

Notes:
The function is listed correctly in Alt-M.
It's also listed in 'Find Symbols'.
Alt-Up/Down correctly jumps to the Next/Prev functions in the file.
"Parse all files when opening a project" is ON.
"Reparse Current File" doesn't help.



Any ideas/fixes?

Thanks!

Edited by - JanSolo on Jan 06 2012 6:23:52 PM

accord
Whole Tomato Software

United Kingdom
3287 Posts

Posted - Jan 09 2012 :  3:40:16 PM  Show Profile  Reply with Quote
As far as I can remember, this type of problem can be caused by specifying include directories as global instead of a project specific additional directory for files that may be changed. VA doesn't re-parse global, system directories when you modify them. This may help a little bit:

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

Can you please try what happens if you manually open the cpp file where the definition resides for a method, and then choose

VAssistX -> Tools -> Reparse current file

Does Alt+G start working on that method after this?

Also, rebuilding symbol databases might help:

VA Options -> Performance -> Rebuild

Edited by - accord on Jan 09 2012 3:42:15 PM
Go to Top of Page

JanSolo
New Member

Canada
2 Posts

Posted - Jan 10 2012 :  1:48:00 PM  Show Profile  Reply with Quote
quote:
Originally posted by accord

As far as I can remember, this type of problem can be caused by specifying include directories as global instead of a project specific additional directory for files that may be changed. VA doesn't re-parse global, system directories when you modify them. This may help a little bit:

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



I will try playing with these a little bit. I'll reply again if it fixes things.

quote:

Can you please try what happens if you manually open the cpp file where the definition resides for a method, and then choose

VAssistX -> Tools -> Reparse current file

Does Alt+G start working on that method after this?



Nope. If I Alt-G a function, it just takes me to the header. Even if the function is declared in the same cpp file. Alt-G from the header does nothing.

quote:

Also, rebuilding symbol databases might help:

VA Options -> Performance -> Rebuild



Again, No difference.
Go to Top of Page

accord
Whole Tomato Software

United Kingdom
3287 Posts

Posted - Jan 10 2012 :  2:50:38 PM  Show Profile  Reply with Quote
Can you please try creating a new win32 project to see whether alt+g works there? You can create a very simple class in the header with a method declaration and a simple implementation in the cpp, just to see if the problem is with your project setting or with something else (maybe a global setting?)

Does alt+o work in the test project? And what about your real project?
Go to Top of Page

dts
New Member

6 Posts

Posted - Mar 25 2012 :  07:04:34 AM  Show Profile  Reply with Quote
Got the same issue.

Alt+G from header file only works rarely.

From what i noticed this is a regression in revisions above 1859, that is the last revision where it seems to work fine.

1862 and 1901 that particular feature seems to be broken (for bigger projects at least).
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Mar 26 2012 :  2:28:38 PM  Show Profile  Reply with Quote
Are you working with "using namespace" lines? This has been known to cause similar problems.

If you are able to post a code sample that reproduces the problem this would be very helpful, to help us work out what the trigger might be.

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

dts
New Member

6 Posts

Posted - Mar 28 2012 :  1:30:20 PM  Show Profile  Reply with Quote
There are a few namespaces present but not covering all the code.

Unfortunately i can not share the actual code in question.

But i could easily reproduce the issue with an open source project (https://github.com/TrinityCore/TrinityCore).

Here is a guide how to produce VS solutions using cmake (http://www.trinitycore.info/How-to:Win).

Thanks for looking into this.

p.s. Due to this projects size it seems like being somewhat of a stress-test for VA. I noticed reference resolution randomly stopped working when making changes of bigger files.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Mar 28 2012 :  2:49:02 PM  Show Profile  Reply with Quote
Thank you for the link to a test project, I am following the steps to get this now. When I have the project, which files are you seeing this Alt-g problem with? Or should I be able to reproduce this in any file?

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

dts
New Member

6 Posts

Posted - Mar 28 2012 :  3:39:56 PM  Show Profile  Reply with Quote
It pretty much occurs randomly at various files. The "game" project is the one in question though.

I just removed all previous VA parse data, started VS, waited for the parsing to finish and then tried with ArenaTeam.h and Disband() - didn't work.

When i use the feature on ArenaTeam::Disband() in the corresponding .cpp file, it suggests me equally named functions from the Guild class..?

I also just noticed that the "Find references" features errors out with "Find References is not available because the symbol is unrecognized".


Go to Top of Page

dts
New Member

6 Posts

Posted - Mar 28 2012 :  3:42:54 PM  Show Profile  Reply with Quote
Just a question that popped into my mind:

Is it even recommended running VA without IntelliSense? I've been doing that for a while now since VS seems to react/act _way_ faster with VA only than with having it enabled.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Mar 28 2012 :  9:45:22 PM  Show Profile  Reply with Quote
So far no sign of any problems. I have followed the bulk of the instructions, and I have the source code and solution.

I have created a VS2008 solution, since you did not specify the IDE you are using, and this seemed a good guess, and it lets me upgrade to VS2010.

Using VA 1901, VA is reporting 1,694 files in this solution, which is quite small, so there should be no stress due to the solution size. I have opened the file "ArenaTeam.cpp", gone to line 335, alt-g on "Disband" takes me directly to the header file, the function declaration. Alt-g here goes directly back to the cpp file, and the function declaration.

Sitting in the cpp file, if I trigger Find References on the function name, VA finds 5 references in 4 files.

Which IDE and version of VA are you using? How many files do you have in this test solution?

If you open VA's Open File in Solution dialog (Alt-Shift-O) the title bar contains two numbers. The first number is the number of files currently listed, which changes as you filter the list. The second number is the total number of files in the list, which is normally the number of files in your solution. What is this second number?


As for disabling IDE intellisense, this is fairly common:

http://docs.wholetomato.com?W133

It does not stop VA working, it just means that turning on:

VA Options -> Advanced -> Listboxes -> Get content from default Intellisense

is not going to work. Also some IDE features are disabled, but the benefit is that things are faster, since you only have one code parser running.

zen is the art of being at one with the two'ness

Edited by - feline on Mar 28 2012 9:56:29 PM
Go to Top of Page

dts
New Member

6 Posts

Posted - Mar 29 2012 :  08:45:56 AM  Show Profile  Reply with Quote
My bad, i'm running VS2010 and encountering the issues with VA 1901.

Sadly the problems seem to appear at random, i cleaned out the VA parsing data once again and after reparsing "Find references" was non-functional directly after startup.

Usually removing the .suo file and restarting VS solved those problems.

But like said before, 1859 seems to work way better in that regard. Any rev. above that has these issues.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Mar 29 2012 :  11:18:49 AM  Show Profile  Reply with Quote
The .suo file is an IDE file, it should not have any effect on VA, unless it was corrupt and causing the IDE its self problems.

Lets go back to basics. Which OS are you using, and is this 32bit or 64bit?
How have you disabled VS2010 intellisense?

What steps are you taking to see Find References not working, and how, exactly, are you triggering Find References? I am wondering if you could somehow be triggering an IDE command, not a VA command. If you have disabled IDE intellisense, and then ask the IDE to do something that relies on IDE intellisense this will fail.

Can you please try the following test steps.

Make sure there are no instances of VS2010 running.
Load VS2010, but don't load any solutions.
Press the button:

VA Options -> Performance -> Rebuild symbol databases

close VS2010, wait a few seconds, then load VS2010.
Load the TrinityCore test solution, and load the file "ArenaTeam.h"
Wait for all parsing messages to disappear from IDE status bar and for VA to apply its syntax highlighting to the code.
Go to line 123, and place the caret in the symbol "Disband". At the top of the editor VA should be showing:

Context field = ArenaTeam.Disband
Definition field = void Disband(WorldSession* session)

if you are seeing the same thing, assuming you have the VA context and definition fields turned on, use the VAssistX menu to trigger the command:

VAssistX menu -> Find References

what happens?

You should either get a message box saying "Find References is not available because the symbol is unrecognised." or the Find References Results window should appear, and VA should start running a Find References scan of the solution.

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

dts
New Member

6 Posts

Posted - Mar 29 2012 :  4:28:45 PM  Show Profile  Reply with Quote
Win7 x64
IS disabled via: Options->Text Editor-C/C++->Advanced->Disable database

Followed your instructions, tried three times, every time with the same result:

When parsing finishes i get the error msg "Find References is not available because the symbol is unrecognised." and the context field shows "ArenaTeam.h".

After restarting VS and reloading the solution, it suddenly starts working.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Mar 30 2012 :  12:01:43 PM  Show Profile  Reply with Quote
This is rather unexpected, this works correctly for me the first time I load VA and the test solution after a symbol database rebuild.

Can you please export your VA and IDE settings and send them to me:

VA Options -> Performance -> Export Settings
IDE tools menu -> Import and Export Settings -> Export selected environment settings

I can then import them here and see if I can reproduce the problem.

If you have edited your VA StdAfx.h file can you please send me your edited file. Editing VA's StdAfx.h file is explained in this FAQ entry:

http://docs.wholetomato.com?W302

I am wondering if your file has been edited, and if this could be a factor here. I should be using the same solution, I am using the same IDE, OS and version of VA, so the difference must lay somewhere else.

Please submit the files via the form:

http://www.wholetomato.com/support/contact.asp

including this thread ID or URL in the description, so we can match it up.

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

pthiben
New Member

7 Posts

Posted - Apr 23 2012 :  11:42:38 AM  Show Profile  Reply with Quote
Any news on that ? I have a similar issue, which is Goto Declaration in header works, but not in implementation.

I managed to boil it down to:

vabug.h:

#ifndef __MY_HEADER__H__
#define __MY_HEADER__H__

#define myBEGIN_NAMESPACE namespace test {
#define myEND_NAMESPACE namespace }

myBEGIN_NAMESPACE

class MyClass
{
public:
    virtual void MyMethod1();
    void MyMethod2();
};

myEND_NAMESPACE

#endif //#__MY_HEADER__H__



vabug.cpp

#include "vabug.h"


myBEGIN_NAMESPACE

void MyClass::MyMethod1()
{
    MyMethod2(); // Alt-G there and it only goes to the declaration in header file, not 2 lines below :s
}

void MyClass::MyMethod2()
{

}
myEND_NAMESPACE


I'm with VAX 1903, and I already tried the LimitMacro and LimitMacroParsing advice.

Thanks
Go to Top of Page

GregDude
Senior Member

30 Posts

Posted - Apr 23 2012 :  10:58:16 PM  Show Profile  Reply with Quote
I'm interested in this issue also. I'm trialing VAX again for a new project and am having some hit and miss with Alt-G and even Alt-Q. This project has legacy source code with non-matching file names and multiple headers and source files with same namespaces or classes.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Apr 24 2012 :  12:10:02 PM  Show Profile  Reply with Quote
pthiben, unfortunately no news yet. This is down as a high priority bug, but so far we have not found and fixed the problem:

case=14901

This is a little odd, since a similar situation, with more than one nested namespace using macros is fixed by turning on deeper macro parsing.

GregDude, depending on what is causing your problems, you might find that turning on deeper macro parsing helps, as explained in this FAQ entry:

http://docs.wholetomato.com?W363

If this does not help, could you post some sample code to help me understand what is happening in your solution please?

Alt-g should not be stopped by non matching file names, but this will confuse Alt-O, since if the file names don't match, VA won't know which files are supposed to match up. Depending on how many sets of non matching file names you have, and if there are any patterns here to help identify what matches to what, you might find this IDE macro for jumping to a matching file helpful:

http://support.wholetomato.com?W439

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

pthiben
New Member

7 Posts

Posted - Apr 24 2012 :  12:24:28 PM  Show Profile  Reply with Quote
Hi feline,

Are you able to reproduce the bug on your side with the example I provided ?

Thanks
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Apr 24 2012 :  4:33:35 PM  Show Profile  Reply with Quote
Unfortunately yes, I am able to reproduce with your example, and so far the only work around I can find is to search in the Find Symbol dialog, or to use Find References, since this is listing all instances of the function for me.

This is going to be slower than Alt-g, but hopefully this is reliable for you.

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

pthiben
New Member

7 Posts

Posted - Apr 24 2012 :  4:55:17 PM  Show Profile  Reply with Quote
quote:
Originally posted by feline

Unfortunately yes, I am able to reproduce with your example, and so far the only work around I can find is to search in the Find Symbol dialog, or to use Find References, since this is listing all instances of the function for me.

This is going to be slower than Alt-g, but hopefully this is reliable for you.



That's good news for me at least :)

I hope this example is simple enough to track down this nasty bug

Thanks
Go to Top of Page

support
Whole Tomato Software

5566 Posts

Posted - Aug 09 2012 :  01:57:38 AM  Show Profile  Reply with Quote
case=14901 is fixed in build 1912

Whole Tomato Software, Inc.
Go to Top of Page

vjtech
New Member

4 Posts

Posted - Aug 20 2012 :  05:28:09 AM  Show Profile  Reply with Quote
Using following:
MS VisualStudio 2008 C++
VA build 10.7.1912.0

Alt-G (or Go button) still does NOT take you to .cpp file
You can jump from .cpp file to header but not from header to .cpp file

Tried re-parsing files and rebuilding VA databases, nothing helped.
Tried 'Macro parse depth' solution: no luck.

If you use 'Find References' option, it displays the correct list of references and you can jump to .cpp location from there.
If you display 'Code definition' window, it will display the correct file/location.
It if just Alt-G which does not want to work.


Alt-G is the most frequently used function (by me)
Needless to say that this issue is very annoying.
Best of luck in finding it.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18721 Posts

Posted - Aug 20 2012 :  2:09:53 PM  Show Profile  Reply with Quote
Do you have this problem with all code, or with only some code?

You mention turning on macro parse depth, so is this problem only showing up on code that uses macros? Would you be able to post a simple code sample that shows the problem you are having?

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

benblo
New Member

2 Posts

Posted - Aug 21 2012 :  08:38:51 AM  Show Profile  Reply with Quote
Same problem here, alt+g only ever brings me to the .h, never the .cpp. This is global, all the code, the whole solution, not just some classes.

If I alt+g from another class, I don't have the dropdown I had before asking for the location ("h or cpp"), and if I alt+g from the h it stays there, still doesn't bring me to the cpp.
I checked, alt+g is still mapped to the "goto implementation" command.

I'm on VC++ 2010 10.0.30319.1 RTMRel, Visual Assist X 10.7.1912.0 build 2012.08.08.

I tried to rebuild the symbol DB and clear history & cache, no dice.

Edited by - benblo on Aug 21 2012 08:40:06 AM
Go to Top of Page

benblo
New Member

2 Posts

Posted - Aug 21 2012 :  08:46:43 AM  Show Profile  Reply with Quote
Reverting to build 1901 "fixed it" for me... it's back to the old icons for me ;) !
Shame because 1912 seemed to have nice improvements.
Go to Top of Page

vjtech
New Member

4 Posts

Posted - Aug 21 2012 :  09:55:45 AM  Show Profile  Reply with Quote
Yes, the problem appears to be after custom BEGING END construction using custom made message map.
All macros are defined in .h header file.

In .cpp file I have the construction shown below.
Before this BEGIN END block everything works ok.
After this block Alt-G stops working

.cpp file
BEGIN_MY_MESSAGE_MAP(CItemList,CSomeWindowBase)
ON_MY_MESSAGE( WM_ITEM_EVENT, OnItemEvent )
ON_MY_MESSAGE( WM_LBUTTONDOWN, OnLButtonDown )
ON_MY_MESSAGE( WM_HANDOVER_LBUTTONDOWN, OnHandoverLButtonDown )
ON_MY_MESSAGE( WM_LBUTTONUP, OnLButtonUp )
ON_MY_MESSAGE( WM_MOUSEMOVE, OnMouseMove )
ON_MY_MESSAGE( WM_SET_LIST_VELOCITY, OnSetListVelocity )
ON_MY_MESSAGE( WM_TIMER, OnTimer )
END_MY_MESSAGE_MAP()

Please let me know if you need more information on message map definitions.
Go to Top of Page

sean
Whole Tomato Software

USA
2817 Posts

Posted - Aug 21 2012 :  9:35:03 PM  Show Profile  Reply with Quote
mail sent to benblo and vjtech via support
Go to Top of Page

vjtech
New Member

4 Posts

Posted - Aug 22 2012 :  03:59:13 AM  Show Profile  Reply with Quote
I tried the proposed solution, unfortunately it did not help.
The behaviour is exactly the same as before.
I will try to make a simple project reproducing the issue and send it to support
mentioning case number which was sent to me in e-mail.

Thanks for help.
Go to Top of Page

pwc
Tomato Guru

138 Posts

Posted - Aug 24 2012 :  3:30:20 PM  Show Profile  Reply with Quote
I'm seeing the same thing (alt-g doesn't navigate from header to source). This pretty much renders 1912 unusable.
Go to Top of Page

pthiben
New Member

7 Posts

Posted - Aug 24 2012 :  3:53:49 PM  Show Profile  Reply with Quote
1912 seemed to resolve most of our cases here.

Unfortunately, I can't repro the remaining files that still have the problem =/
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Next Page
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000