Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 VA Navigation Bar list incomplete

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
andreypir Posted - Sep 25 2017 : 8:02:43 PM
For fairly large .cpp files VA Navigation Bar dropdown does not list some class members.
6   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Sep 26 2017 : 5:30:59 PM
Thank you for the update, and apologies for the problems this is causing. Partly the problem happens because VA is designed to scan the code inside the #if blocks, even if it is inactive, so that we can help you when you are working on and editing this code. But the side effect is that we see and can be confused by unmatched brackets.

If you don't know about it, selecting lines of code and pressing / or * to comment and uncomment the code is a helpful VA feature that can help you to avoid problems like this, since commented out code is not parsed by VA.
andreypir Posted - Sep 26 2017 : 4:46:34 PM
Yes, adding a matching commented out bracket fixes the problem. Thank you for looking into this, and hope to have it fixed as we have more files like this.
feline Posted - Sep 26 2017 : 2:40:57 PM
Thank you for the very clear example. Since this seems to be a minimum example, the problem goes away when I try simplifying the code any more, have you already found a fix for this in your code? I am happy to help you do so if not.

Mostly our parser is able to recover from code with mismatched brackets due to pre-processor blocks, but not in this case. I have added this example to the case where we are working on this problem:

case=4222
andreypir Posted - Sep 26 2017 : 1:33:51 PM
Thank you, using Occurrence option I was able to locate the problem. Here is a code snippet that makes it trip, the navigation lists F1 but not F2.

HRESULT A::F1() const
{
DWORD a = 0, b = 0, c = 0, d = 0;
#if 1
while (c < d)
{
if (!(b == 0 || (a >= b)))
{
#if 0 // for testing
#endif
}
#else
while (c < d)
{
#endif // 1
}
return S_OK;
}

HRESULT A::F2() const
{
return S_OK;
}
feline Posted - Sep 26 2017 : 06:31:21 AM
If you set the list to be in Occurrence order:

VA Options -> Display -> Display VA Navigation Bar:
Occurrence

are the missing members grouped together? If so, are they at the end of the file? If something is confusing our parser, then its possible that everything after the problem point is missing from the list. If so, this should help to narrow down the function / part of the file where the confusion is starting.
ChrisG Posted - Sep 25 2017 : 9:42:48 PM
Hey andreypir,

I'm sorry you are having this trouble.

Perhaps there is something specific tripping the parser up. Is there anything you notice that is different about the members that aren't picked up?

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