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
 "List methods in current file" shows entries twice
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

stefan_reinalter
New Member

Austria
5 Posts

Posted - Sep 24 2021 :  04:07:43 AM  Show Profile  Reply with Quote
On my current project/solution, VAX will always show every function twice when pressing ALT + M.
This only happens in that particular solution, and I already tried nuking all intermediate files (e.g. deleting the whole dev folder and resyncing everything from version control).

Any idea what's going on?



feline
Whole Tomato Software

United Kingdom
18749 Posts

Posted - Sep 24 2021 :  06:59:08 AM  Show Profile  Reply with Quote
No instant ideas, no.

If you go to each entry for "CenterWindowToParent" does VA take you to the same line? Or are the two entries taking you to different lines?

If you right click the open Alt-M list, are all of the "Include" options turned On? What about displaying namespace scopes? So:

Include defines = On
Include events = On
Include members = On
Include properties = On
Include regions = On
Include scope = On
Reduce display of namespace scopes = OFF

I am wondering if there is anything going on that might give us a clue. I am also interested in making sure that reduce namespace scopes is Off, just in case, for some reason, the two entries are being listed with different namespace scopes.

If you copy / paste this file pair into a new, default solution, do you still see this problem? I know you have said this is solution specific, so I am just checking to see if its a function of the files alone, or the files plus the solution.

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

stefan_reinalter
New Member

Austria
5 Posts

Posted - Sep 24 2021 :  07:25:16 AM  Show Profile  Reply with Quote
quote:
Originally posted by feline

No instant ideas, no.

If you go to each entry for "CenterWindowToParent" does VA take you to the same line? Or are the two entries taking you to different lines?



Always takes me to the same line, in each file where this happens.

quote:
Originally posted by feline

If you right click the open Alt-M list, are all of the "Include" options turned On? What about displaying namespace scopes? So:

Include defines = On
Include events = On
Include members = On
Include properties = On
Include regions = On
Include scope = On
Reduce display of namespace scopes = OFF

I am wondering if there is anything going on that might give us a clue. I am also interested in making sure that reduce namespace scopes is Off, just in case, for some reason, the two entries are being listed with different namespace scopes.



I had "Reduce display of namespace scopes" turned on, but turning it off didn't change a thing.

quote:
Originally posted by feline

If you copy / paste this file pair into a new, default solution, do you still see this problem? I know you have said this is solution specific, so I am just checking to see if its a function of the files alone, or the files plus the solution.



Ha, perfect question, because as it turns out, it's also broken when pulling the .h/.cpp pair into a completely blank solution.

Which got me thinking that it must be connected to how the code is written, so I started investigating. Turns out it's caused by the LPP_NO_EXCEPT macro those functions are defined with, so here's a repro for you:


void Function(void)
{
}

void FunctionWorks(void) noexcept
{
}

#define LPP_NO_EXCEPT noexcept

void FunctionFails(void) LPP_NO_EXCEPT
{
}


Function() and FunctionWorks() are only shown once in the list.
FunctionFails() is shown twice, seems like VAX gets confused by the macro at the end.

I also noticed that LPP_NO_EXCEPT is shown in the same color as a type, and not in the color of a macro. Maybe that gives you a hint of what's going on.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18749 Posts

Posted - Sep 24 2021 :  08:56:56 AM  Show Profile  Reply with Quote
I would not expect that, but I am seeing mostly the same effect here. The macro is being coloured as a macro for me, but I am seeing the double entries in the Alt-M list.

The following has fixed the problem for me, so let's see if it helps you. Please create a new text file called "va_stdafx.h" in the same directory as your SLN file. This is a solution specific fix, so if you are trying in the test solution first, which is probably faster, you will need to copy the file across to your main solution and do another rebuild, just to be sure. Edit this file and add the line:

#define LPP_NO_EXCEPT

making sure that the file ends with a blank line.

When rebuilding its symbol database VA searches for this file, and if found, it parses it before parsing anything else. This file is used to give our parser helpful hints, and to work around odd problems that we encounter. The file should not be added to your solution, so it doesn't matter if the content of the file conflict with code inside your solution.

Having created and edited the file, in the IDE press the button:

VA Options -> Performance -> Rebuild symbol databases

and restart your IDE.

I have put in a bug report for this, since it really should not be happening:

case=146242

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

stefan_reinalter
New Member

Austria
5 Posts

Posted - Sep 24 2021 :  09:05:05 AM  Show Profile  Reply with Quote
Unfortunately, your suggested workaround doesn't work for me.
I added the file with #define LPP_NO_EXCEPT (and blank lines) to both the solution and project directories, rebuilt the VAX database, but the problem still persists.

Don't worry about trying other workarounds, I'll just wait for the bug fix to arrive.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18749 Posts

Posted - Sep 24 2021 :  11:41:18 AM  Show Profile  Reply with Quote
Please be aware I cannot yet give you an estimate for when we will have a fix, plus, the work around works here, so there is no guarantee that a fix for the problem I am seeing, that is fixed with the workaround, will fix it for you. I would expect it to fix the problem you are seeing, but I also expected the work around to work for you.

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