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
 Find References not working after update 2023.2
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

FAN
Senior Member

33 Posts

Posted - May 03 2023 :  02:43:46 AM  Show Profile  Reply with Quote
I'm using Visual Studio 17.5.4 and after updating to Visual Assist 2023.04.25 (general release), Find References doesn't work anymore.

It still shows the implementation in the header and the cpp file, but nothing else.

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 03 2023 :  05:45:47 AM  Show Profile  Reply with Quote
Can you explain exactly how Find References doesn't work please.

Is the menu command disabled?
Can you trigger the command, but it gives you an error message telling you the symbol is not recognised.
It is running, but only some references are being returned? It sounds like this is what you are seeing.

Can you please try the following simple test case:

static void testPrePostOperators()
{
	int nCounter = 0;
	nCounter++;
	nCounter--;
	nCounter += 2;
	nCounter *= 3;
	nCounter /= 4;
	++nCounter;
	--nCounter;
}

and trigger Find References on any instance of "nCounter". What results do you see?

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

FAN
Senior Member

33 Posts

Posted - May 03 2023 :  07:11:50 AM  Show Profile  Reply with Quote
I call a function on a std::unique_ptr. Before the update, VA was able to find the reference.

Please find attached a picture of the working version and the version after the update, which does not show the reference anymore.








Your test with nCounter seems to work fine and shows all the references.



Edited by - FAN on May 03 2023 09:13:11 AM
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 04 2023 :  08:20:03 AM  Show Profile  Reply with Quote
Interesting. Are you seeing this problem a lot, or just in a few places?

Can you please try the following test case, which as the comments indicate, works correctly for me:

class CFelineUniqueShapeSquare
{
public:
	// testing Find References on these two member functions - always finds 2 results
	void RenderFillShape() {}
	std::string GetSquareName() { return "Yellow Square"; }
};
	
class CFelineUniqueShapeCircle
{
public:
	// testing Find References on these two member functions - always finds 2 results
	void RenderFillShape() {}
	std::string GetCircleName() { return "Blue Circle"; }
};
	
void FelineStdUniquePtr()
{
	std::unique_ptr<CFelineUniqueShapeSquare> uniqueSquarePtr;
	std::unique_ptr<CFelineUniqueShapeCircle> uniqueCirclePtr;
	
	// testing Find References on these two function calls - always finds 2 results
	uniqueSquarePtr->RenderFillShape();
	uniqueSquarePtr->GetSquareName();
	
	// testing Find References on these two function calls - always finds 2 results
	uniqueCirclePtr->RenderFillShape();
	uniqueCirclePtr->GetCircleName();
}

I suspect it isn't std::unique_ptr that is the problem, but that the problem is something else, around the function call that isn't being picked up.

If you go to the missing result in your source code and place the keyboard caret into the function call "openPort" what, if anything, is shown in VA's context and navigation fields? If they are blank then it means VA isn't able to correctly parse this line of code, which would explain why this function call isn't being shown in the Find References Results window.

If you right click in the Find References Results and turn On:

Display unknown/guess hits (G)

in the context menu then this missing result should be shown with a question mark icon, showing that VA isn't sure it is a correct result.

If this is what is going on then we need to try to work out why our parser is getting confused.

Are the Alt-M list and VA Outline looking correct in this file? Sometimes if something is confusing our parser it will show up here, with functions being missing or listed incorrectly. This can often help to narrow down where the problem starts.

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

FAN
Senior Member

33 Posts

Posted - May 05 2023 :  07:51:57 AM  Show Profile  Reply with Quote
Nevertheless, the problem seems to be with the unique_pt.

I adjusted your function like this:
void FelineStdUniquePtr()
{
std::unique_ptr<CFelineUniqueShapeSquare> uniqueSquarePtr;
std::unique_ptr<CFelineUniqueShapeCircle> uniqueCirclePtr;

CFelineUniqueShapeCircle c;
c.RenderFillShape();


// testing Find References on these two function calls - always finds 2 results
uniqueSquarePtr->RenderFillShape();
uniqueSquarePtr->GetSquareName();

// testing Find References on these two function calls - always finds 2 results
uniqueCirclePtr->RenderFillShape();
uniqueCirclePtr->GetCircleName();
}


My computer with the old VA version shows this result:



but the new version only shows this:




VA Outline looks fine to me.


How can I turn on Display unknown/guess hits (G) in Find References Results?
This option is not being shown to me at all.


By the way, if I use VA Rename to rename openPort, it does not work for the unique_ptr.


Edited by - FAN on May 08 2023 09:53:03 AM
Go to Top of Page

FAN
Senior Member

33 Posts

Posted - May 08 2023 :  07:56:31 AM  Show Profile  Reply with Quote

It is the unique_ptr that is causing the problem. As soon as I replace it with a std::shared_ptr, all references are found.

I am now testing on three different computers:

  • A: Visual Assist 2023_1 is installed and the unique_ptr is found.

  • B: Visual Assist 2023_2 is installed and the unique_ptr is not found.

  • C: 2023_1 was installed and uniqur_ptr was found. I installed 2023_2 and it was not found anymore. I uninstalled 2023_2 and installed 2023_1 again but unique_ptr is still not found!



Did installing 2023_2 change any settings?


Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 08 2023 :  12:40:53 PM  Show Profile  Reply with Quote
Installing a newer version of VA should not effect your settings. I still cannot reproduce this problem here either. I am currently assuming that this bug is caused by something else, outside of this code snippet. This is either something in your solution, or something in one of your stable include directories.

Can you please try making a new, default C++ console solution, and copying the simple test case into it, and see if you get the same problem there?

Another thing to try is pressing the button:

VA Options -> Performance -> Rebuild symbol databases

and then restarting Visual Studio. This should only take a couple of minutes, unless you are working with a really massive solution. This will help to clear out any odd results in VA's symbol database, but since this effect is seen across different computers I doubt this will make any difference.

Am I correct in assuming you are using the same solution on all 3 computers that you are seeing the problem on?

Rename uses Find References, so if Find References isn't picking up the function call then you will get the same result with Rename. That bit at least makes sense.

For the guess hit entry in the VA context menu, this is only listed if there are guess hits to list. I am rather confused as to why this option isn't listed for you, since if VA doesn't understand the scope of the function call, which is why the result isn't being listed in Find References Results, it should still be listed as a guess result.

If you try the following simple test case, this will show a guess result in the Find References Results list when you do a Find References on the function "GuessThisFunctionCallOnUnknownSymbol"

class ForcingFindReferencesToGuess
{
public:
	void GuessThisFunctionCallOnUnknownSymbol() { }
};

void forcingFindRefUnknownGuessReference()
{
	ForcingFindReferencesToGuess localKnown;
	localKnown.GuessThisFunctionCallOnUnknownSymbol();
#ifdef VA_VALID_CODE_BUT_DOES_NOT_COMPILE
	localUnknown.GuessThisFunctionCallOnUnknownSymbol();
#endif // VA_VALID_CODE_BUT_DOES_NOT_COMPILE
}

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

FAN
Senior Member

33 Posts

Posted - May 09 2023 :  06:07:55 AM  Show Profile  Reply with Quote

I did create a new default C++ console solution but it was not able to find a unique_ptr reference.

Rebuild symbol databases did not fix the problem. Clear history did not help either.
Should I enable logging under VA Options -> Performance?





First I tested the same solution on all 3 computers, but I also tested with a new default C++ console solution. The unique_ptr reference does not work with 2023_2.


Your latest example (ForcingFindReferencesToGuess) works fine for 2023_1 and 2023_2.






Go to Top of Page

FAN
Senior Member

33 Posts

Posted - May 09 2023 :  10:22:56 AM  Show Profile  Reply with Quote
We have now investigated the bug with four other members of my team. These four are using Visual Assist 2023.1 (10.9.2476.0). Including myself, 3 out of 5 people have the bug that the reference is not found on the unique_ptr.

We have now determined that the problem is related to the combination of the Visual Studio version and the Visual Assist version.

  • The two people using Visual Studio 17.5.33530.505 (17.5.4) do not have the bug.

  • The three people using Visual Studio 17.5.33627.172 (17.5.5) have the bug.



(Visual Studio 17.5.33627.172 was released on May 1, 2023.)


Edited by - FAN on May 09 2023 10:33:59 AM
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 09 2023 :  10:56:25 AM  Show Profile  Reply with Quote
That actually makes a bit more sense. I am still on VS2022 version 17.5.4, updating now. The update to VS2022 may well have introduced a change to the library header that declares unique_ptr, which would explain why it is a factor.

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

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 09 2023 :  12:06:12 PM  Show Profile  Reply with Quote
Progress of a form, I have this happening in one solution, but not in another. No bug in my main test solution, but the bug does show up in a new default console solution. Running more tests now, but seeing the problem here is going to make investigating this a lot easier. I am hoping to find a work around fix for you, but I need to understand why the two solutions are working differently first.

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

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 11 2023 :  10:53:48 AM  Show Profile  Reply with Quote
I have confirmed the problem first appears in VS2022 version 17.5.0, and happens with both VA build 2476 and build 2488

case=149519

I am now trying to find out exactly what changed in the system header files to cause the problem, in the hopes that this gives us a work around.

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

FAN
Senior Member

33 Posts

Posted - May 12 2023 :  02:33:58 AM  Show Profile  Reply with Quote

Thanks for the feedback. I'm happy to test as soon as you have a possible fix.


Go to Top of Page

FAN
Senior Member

33 Posts

Posted - May 17 2023 :  03:59:39 AM  Show Profile  Reply with Quote

Can you estimate a timeline? Find reference is one of the most important features for me and I think for many others.

Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 17 2023 :  08:38:31 AM  Show Profile  Reply with Quote
I have been trying to understand the problem, in the hopes of finding a work around. I think I now have a work around. To try this, you first need to locate the VA install directory, which will be:

%USERPROFILE%\AppData\Local\Microsoft\VisualStudio\17.0_xxxxx\Extensions\yyyyyyy.yyy
where xxxxx and yyyyyyy.yyy are two different machine specific hashes. The VA install directory contains the file "VA_X64.dll", so if there is more than one installed extension you can check for this file to work out which one holds VA.

Inside the VA install directory you need to locate the file:

Misc\StdAfx.h

open this file in a text editor, and at the end of the file add the line:

#define _EXPORT_STD 

making sure the file ends with a blank line. Save the edit. You now need to trigger a VA symbol database rebuild for this change to be picked up, which you do via:

VA Options -> Performance -> Rebuild symbol databases

after the rebuild has finished, does this fix the problem? It is fixing the problem for me here.

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

FAN
Senior Member

33 Posts

Posted - May 24 2023 :  05:37:29 AM  Show Profile  Reply with Quote

Thank you very much for the help. It worked

Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 24 2023 :  08:21:47 AM  Show Profile  Reply with Quote
Thank you for the update. This worked here for me, but it is always good to know that it worked well for you as well We are looking into a proper fix for this problem.

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

FAN
Senior Member

33 Posts

Posted - May 30 2023 :  09:55:30 AM  Show Profile  Reply with Quote

Not sure if this is directly related to your fix, but code inspection has now stopped working completely.

I have since updated Visual Studio to 17.6.2 (released May 25). Maybe the problem has something to do with this VS version.

Currently, code inspection does nothing. As you can see in the screenshot, it should complain about void in the destructor.




Can you reproduce the behavior? For me, Code Inspection does not even show a message that it is reparsing the file.

I can reproduce the problem on multiple computers.
Code inspection and automated reparsing are enabled.

Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 30 2023 :  1:39:42 PM  Show Profile  Reply with Quote
Code Inspection is working quite happily for me, and I am fairly sure it worked when trying this fix here. I am just going to double check that statement though.

Can you please try making a new, default C++ solution and adding the following simple test function to a cpp file. This should pick up a couple of different issues, as indicated by the comments.

// three picked up here, shown by pale text, no underline #CodeInspectRedundantVoid
static void testRedundantChecks(void)
{
	for(int nScan = 1; nScan < 10; ++nScan)
	{
		continue;  // #CodeInspectRedundantFlow
	}

	return; // #CodeInspectRedundantFlow
}


also we have just released VA build 2023.3 (version 2491) which you can download from here:

http://www.wholetomato.com/downloads

which contains a fix for the std::unique_ptr problem. Code inspection is active and working normally for me with this latest build.

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

FAN
Senior Member

33 Posts

Posted - May 31 2023 :  03:36:49 AM  Show Profile  Reply with Quote

I have updated to the latest version of VA and can confirm that Code Inspection works perfectly well for a new, standard C++ solution.

However, it does not work at all for our existing (large) solution. Not even when I copy your simple test function into an existing file.

The behavior gets even weirder. As soon as I create a new header file for the existing project (and place your test function there), code inspection suddenly works for the entire project within the solution.

When I delete the newly created file from the project, the code inspector stops working for the entire project again.

As mentioned last time, not even the message that VA is parsing appears.

What do you suggest we do to resolve this issue as soon as possible?
(I'm afraid I can't provide you with our solution.)

Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - May 31 2023 :  06:35:41 AM  Show Profile  Reply with Quote
I assume code inspection worked normally in VA 2476.0? It seems safe to assume you would have said if it had been broken then.

Thank you for checking the new solution, at least we know this is somehow solution specific. Can you please turn On VA logging, via:

VA Options -> Performance -> Enable logging

then change code files a couple of times, opening files that Code Inspection should scan. Now please close the IDE, simply to stop the log files from getting to large. The log file we are looking for should be:

%TEMP%\VaCodeInspections.log

hopefully this will give us some clues. It should not contain any sensitive information.

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

FAN
Senior Member

33 Posts

Posted - May 31 2023 :  09:53:45 AM  Show Profile  Reply with Quote

It does not seem to be related to the VA version, but to the VS version.

I'm currently testing the old, large solution on 4 computers:
- VA 2476 with VS 17.5: Code Inspection works
- VA 2491 with VS 17.5: Code Inspection works
- VA 2491 with VS 17.6.2: Code Inspection does not work
- VA 2488 with VS 17.7 Preview 1: Code Inspection does not work


What is the best way for me to send you the VaCodeInspections.log?
For now, I just put the content in here.
I've been switching back and forth between 3 files. For all of them, code inspection did not work.


[QAT] fileParser null
Servers: 1 alive, 0 failed, 0 restarted
Total messages: 7
Pool connections: ready(1), borrowed(0), reused(6), launched(1)
Wrappers count: cct(1), ccc(1)
Messages:

  SendMessage_wait: SourceManager::Initialize: cnt(1), total(45.0008ms), avg(45.0008ms), max(45.0008ms)
  SendMessage_complete: SourceManager::Initialize: cnt(1), total(52.466ms), avg(52.466ms), max(52.466ms)
  SendMessage_wait: SourceManager::EnableLogging: cnt(3), total(5.003ms), avg(1.66766666666667ms), max(2.0026ms)
  SendMessage_complete: SourceManager::EnableLogging: cnt(3), total(5.003ms), avg(1.66766666666667ms), max(2.0026ms)
  SendMessage_wait: SourceManager::ClearCaches: cnt(2), total(1ms), avg(0.5ms), max(1ms)
  SendMessage_complete: SourceManager::ClearCaches: cnt(2), total(1ms), avg(0.5ms), max(1ms)
  SendMessage_wait: SourceManager::GetAvailableCheckers: cnt(1), total(79.0006ms), avg(79.0006ms), max(79.0006ms)
  SendMessage_complete: SourceManager::GetAvailableCheckers: cnt(1), total(79.9995ms), avg(79.9995ms), max(79.9995ms)

ERROR: Exception: Unbekannter Fehler (Exception from HRESULT: 0x80004005 (E_FAIL))
   Callstack =    at Microsoft.VisualStudio.VCProjectEngine.IVCCollection.Item(Object Index)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.WalkVCConfiguration(VCProject vcProject, VCConfiguration vcConfig, CompilationOptions options)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.GetCompilationOptions(Object projectObject, Object projectItemObject, String configurationName)

   at WholeTomato.VaCodeInspections.e.o()
[RFP] compilationOptions null
[QAT] fileParser null
[QDT] fileParser null
[QAT] fileParser null
ERROR: Exception: Class not registered



Class not registered


   Callstack =    at Microsoft.VisualStudio.VCProjectEngine.IVCCollection.Item(Object Index)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.WalkVCConfiguration(VCProject vcProject, VCConfiguration vcConfig, CompilationOptions options)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.GetCompilationOptions(Object projectObject, Object projectItemObject, String configurationName)

   at WholeTomato.VaCodeInspections.e.o()
[RFP] compilationOptions null
[QDT] fileParser null
[QAT] fileParser null
ERROR: Exception: Class not registered



Class not registered


   Callstack =    at Microsoft.VisualStudio.VCProjectEngine.IVCCollection.Item(Object Index)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.WalkVCConfiguration(VCProject vcProject, VCConfiguration vcConfig, CompilationOptions options)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.GetCompilationOptions(Object projectObject, Object projectItemObject, String configurationName)

   at WholeTomato.VaCodeInspections.e.o()
[RFP] compilationOptions null
[QDT] fileParser null
[QAT] fileParser null
ERROR: Exception: Unbekannter Fehler (Exception from HRESULT: 0x80004005 (E_FAIL))
   Callstack =    at Microsoft.VisualStudio.VCProjectEngine.IVCCollection.Item(Object Index)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.WalkVCConfiguration(VCProject vcProject, VCConfiguration vcConfig, CompilationOptions options)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.GetCompilationOptions(Object projectObject, Object projectItemObject, String configurationName)

   at WholeTomato.VaCodeInspections.e.o()
[RFP] compilationOptions null
[QDT] fileParser null
[QAT] fileParser null
ERROR: Exception: Unbekannter Fehler (Exception from HRESULT: 0x80004005 (E_FAIL))
   Callstack =    at Microsoft.VisualStudio.VCProjectEngine.IVCCollection.Item(Object Index)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.WalkVCConfiguration(VCProject vcProject, VCConfiguration vcConfig, CompilationOptions options)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.GetCompilationOptions(Object projectObject, Object projectItemObject, String configurationName)

   at WholeTomato.VaCodeInspections.e.o()
[RFP] compilationOptions null
[QDT] fileParser null
[QAT] fileParser null
ERROR: Exception: Class not registered



Class not registered


   Callstack =    at Microsoft.VisualStudio.VCProjectEngine.IVCCollection.Item(Object Index)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.WalkVCConfiguration(VCProject vcProject, VCConfiguration vcConfig, CompilationOptions options)

   at WholeTomato.VaCodeInspections.VisualStudio.ProjectItemInspector.GetCompilationOptions(Object projectObject, Object projectItemObject, String configurationName)

   at WholeTomato.VaCodeInspections.e.o()
[RFP] compilationOptions null
Servers: 1 alive, 0 failed, 0 restarted
Total messages: 8
Pool connections: ready(1), borrowed(0), reused(7), launched(1)
Wrappers count: cct(1), ccc(1)
Messages:

  SendMessage_wait: SourceManager::Initialize: cnt(1), total(45.0008ms), avg(45.0008ms), max(45.0008ms)
  SendMessage_complete: SourceManager::Initialize: cnt(1), total(52.466ms), avg(52.466ms), max(52.466ms)
  SendMessage_wait: SourceManager::EnableLogging: cnt(3), total(5.003ms), avg(1.66766666666667ms), max(2.0026ms)
  SendMessage_complete: SourceManager::EnableLogging: cnt(3), total(5.003ms), avg(1.66766666666667ms), max(2.0026ms)
  SendMessage_wait: SourceManager::ClearCaches: cnt(3), total(1.8643ms), avg(0.621433333333333ms), max(1ms)
  SendMessage_complete: SourceManager::ClearCaches: cnt(3), total(1.8643ms), avg(0.621433333333333ms), max(1ms)
  SendMessage_wait: SourceManager::GetAvailableCheckers: cnt(1), total(79.0006ms), avg(79.0006ms), max(79.0006ms)
  SendMessage_complete: SourceManager::GetAvailableCheckers: cnt(1), total(79.9995ms), avg(79.9995ms), max(79.9995ms)

[QDT] fileParser null
[QDT] fileParser null
[QDT] fileParser null
[QDT] fileParser null
Servers: 1 alive, 0 failed, 0 restarted
Total messages: 9
Pool connections: ready(1), borrowed(0), reused(8), launched(1)
Wrappers count: cct(1), ccc(1)
Messages:

  SendMessage_wait: SourceManager::Initialize: cnt(1), total(45.0008ms), avg(45.0008ms), max(45.0008ms)
  SendMessage_complete: SourceManager::Initialize: cnt(1), total(52.466ms), avg(52.466ms), max(52.466ms)
  SendMessage_wait: SourceManager::EnableLogging: cnt(3), total(5.003ms), avg(1.66766666666667ms), max(2.0026ms)
  SendMessage_complete: SourceManager::EnableLogging: cnt(3), total(5.003ms), avg(1.66766666666667ms), max(2.0026ms)
  SendMessage_wait: SourceManager::ClearCaches: cnt(3), total(1.8643ms), avg(0.621433333333333ms), max(1ms)
  SendMessage_complete: SourceManager::ClearCaches: cnt(3), total(1.8643ms), avg(0.621433333333333ms), max(1ms)
  SendMessage_wait: SourceManager::GetAvailableCheckers: cnt(1), total(79.0006ms), avg(79.0006ms), max(79.0006ms)
  SendMessage_complete: SourceManager::GetAvailableCheckers: cnt(1), total(79.9995ms), avg(79.9995ms), max(79.9995ms)
  SendMessage_wait: SourceManager::Shutdown: cnt(1), total(2ms), avg(2ms), max(2ms)
  SendMessage_complete: SourceManager::Shutdown: cnt(1), total(2ms), avg(2ms), max(2ms)



Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - Jun 01 2023 :  07:00:23 AM  Show Profile  Reply with Quote
Since this is both solution and version of Visual Studio specific, I am guessing that the problem is related to a change in some of the standard library header files that ship with VS2022. But if so, it is a different change to the one we already know about. The "fun" is going to be figuring out which directory or set of files to check.

As a first step, can you please open your main solution, where you see this problem, and then go to:

VA Options -> System Info -> Copy Info

and paste the details (from the clipboard) into your reply. I am specifically interested in the system include directories.

I would expect these to be listed in the log file. For reference, here is a snippet from a the same log file generated here, on a system running VS2022 version 17.6.2 where Code Inspection runs without any problems:

[PI.GCO] Sanitize system includes:
[SIP] projectDirectory =
[PI.GCO] Sanitize user includes:
[SIP] projectDirectory = C:\src\ManualVaTests\ManualVaTests_VS2017\ManualVaTests_VS2017[PI.GCO] Sanitize source dirs:
[SIP] projectDirectory =
[SIP] Ignoring non-existent include directory C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\VS\src
[GCO] File options:
- Active Configuration: VS2022_Debug|Win32
- Sys Includes: C:\boost\boost_1_81_0;C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.36.32532\include;C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.36.32532\atlmfc\include;C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\VS\include;C:\Program Files (x86)\Windows Kits\10\Include\10.0.19041.0\ucrt;C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\VS\UnitTest\include;C:\Program Files (x86)\Windows Kits\10\Include\10.0.19041.0\um;C:\Program Files (x86)\Windows Kits\10\Include\10.0.19041.0\shared;C:\Program Files (x86)\Windows Kits\10\Include\10.0.19041.0\winrt;C:\Program Files (x86)\Windows Kits\10\Include\10.0.19041.0\cppwinrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\Include\um;
- User Includes: ;
- Force Includes: ;
- Defines: WIN32;_DEBUG;_CONSOLE;_UNICODE;UNICODE;;IDE_VS2022;_AFXDLL;WIN32;_DEBUG;_CONSOLE;_UNICODE;UNICODE;;IDE_VS2022;_AFXDLL
- Compile as C: False
- C++ Std: 0
- Is 64bit: False
- Flags: -target;x86_64-pc-windows-msvc19.3.0;-nostdinc
- force UTF8: False
[BegTask 2.24] Parse

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

FAN
Senior Member

33 Posts

Posted - Jun 02 2023 :  04:53:19 AM  Show Profile  Reply with Quote

Here is my system info:

VA_X64.dll file version 10.9.2491.0 built 2023.05.24
DevEnv.exe version 17.6.33723.286 Professional
msenv.dll version 17.0.33723.286
Comctl32.dll version 6.10.19041.1110
Windows 10 10.0 22H2 Build 19045.2965
24 processors (x86-64)
Language info: 1252, 0x409

Platform: Project defined
Stable Includes:
C:\Program Files (x86)\Windows Kits\NETFXSDK\4.8.1\Include\um;
C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\cppwinrt;
C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\winrt;
C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\shared;
C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\um;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\VS\UnitTest\include;
C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\ucrt;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\VS\include;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\atlmfc\include;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\include;
C:\SoftwareMain\Development\Sources\Lib\vcpkg\installed\x86-windows\include;

Other Includes:

Stable Source Directories:
C:\Program Files (x86)\Windows Kits\10\Source\10.0.22621.0\ucrt;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\VS\src;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\crt\src;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\atlmfc\src\atl;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\atlmfc\src\mfcm;
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\atlmfc\src\mfc;




As can bee seen from my last post, the problem in VACodeInspections.log is that the fileParser is null.
ERROR: Exception: (Exception from HRESULT: 0x80004005 (E_FAIL))
Callstack = at Microsoft.VisualStudio.VCProjectEngine.IVCCollection.Item(Object Index)


As mentioned above, code inspection starts working as soon as I add a new file to the project. After adding a new project my VACodeInspections.log looks like this:

[EndTask 2.6] 3ms
Servers: 1 alive, 0 failed, 0 restarted
Total messages: 17
Pool connections: ready(2), borrowed(0), reused(15), launched(2)
Wrappers count: cct(2), ccc(2)
Messages:

SendMessage_wait: SourceManager::Initialize: cnt(1), total(77.0011ms), avg(77.0011ms), max(77.0011ms)
SendMessage_complete: SourceManager::Initialize: cnt(1), total(87.0005ms), avg(87.0005ms), max(87.0005ms)
SendMessage_wait: SourceManager::EnableLogging: cnt(6), total(4.9984ms), avg(0.833066666666667ms), max(1.9998ms)
SendMessage_complete: SourceManager::EnableLogging: cnt(6), total(5.9957ms), avg(0.999283333333333ms), max(2.9971ms)
SendMessage_wait: SourceManager::ClearCaches: cnt(2), total(1.0006ms), avg(0.5003ms), max(1.0006ms)
SendMessage_complete: SourceManager::ClearCaches: cnt(2), total(2.0005ms), avg(1.00025ms), max(2.0005ms)
SendMessage_wait: SourceManager::GetAvailableCheckers: cnt(1), total(105.0017ms), avg(105.0017ms), max(105.0017ms)
SendMessage_complete: SourceManager::GetAvailableCheckers: cnt(1), total(106.0015ms), avg(106.0015ms), max(106.0015ms)
SendMessage_wait: FileParser::Constructor: cnt(1), total(13.0007ms), avg(13.0007ms), max(13.0007ms)
SendMessage_complete: FileParser::Constructor: cnt(1), total(16.9996ms), avg(16.9996ms), max(16.9996ms)
SendMessage_wait: FileParser::Parse: cnt(3), total(21272.8982ms), avg(7090.96606666667ms), max(7526.3985ms)
SendMessage_complete: FileParser::Parse: cnt(3), total(21277.898ms), avg(7092.63266666667ms), max(7531.3983ms)
SendMessage_wait: FileParser::Enable: cnt(2), total(1.9989ms), avg(0.99945ms), max(1.9989ms)
SendMessage_complete: FileParser::Enable: cnt(2), total(2.9997ms), avg(1.49985ms), max(2.9997ms)
SendMessage_wait: FileParser::Destructor: cnt(1), total(2.0006ms), avg(2.0006ms), max(2.0006ms)
SendMessage_complete: FileParser::Destructor: cnt(1), total(2.0006ms), avg(2.0006ms), max(2.0006ms)

[PI.GCO] Sanitize system includes:
[SIP] projectDirectory =
[PI.GCO] Sanitize user includes:
[SIP] projectDirectory = C:\SoftwareMain\Development\Sources\Drivers\Sources\Dosage\DrvK[SIP] Ignoring non-existent include directory C:\SoftwareMain\Development\Sources\Drivers\Sources\Dosage\DrvK\..\..\..\..\lib\sources\common
[PI.GCO] Sanitize source dirs:
[SIP] projectDirectory =
[SIP] Ignoring non-existent include directory C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\VS\src
[GCO] File options:
- Active Configuration: Release|Win32
- Sys Includes: C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\include;C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.36.32532\atlmfc\include;C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\VS\include;C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\ucrt;C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\VS\UnitTest\include;C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\um;C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\shared;C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\winrt;C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\cppwinrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.8.1\Include\um;
- User Includes: C:\SoftwareMain\Development\Sources\lib\sources;C:\SoftwareMain\Development\Sources\lib\sources\cslib;C:\SoftwareMain\Development\Sources\lib\sources\boost;C:\SoftwareMain\Development\Sources\Drivers\include;C:\SoftwareMain\Development\Sources\Drivers\Sources\lib;C:\SoftwareMain\Development\Sources\lib\sources\wtl;
- Force Includes: ;
- Defines: WIN32;NDEBUG;_WINDOWS;_USRDLL;UNICODE;_WINDLL;_UNICODE;UNICODE;;
- Compile as C: False
- C++ Std: 0
- Is 64bit: False
- Flags: -target;x86_64-pc-windows-msvc19.3.0;-nostdinc
- force UTF8: False
[BegTask 2.7] Parse
Servers: 1 alive, 0 failed, 0 restarted
Total messages: 19
Pool connections: ready(1), borrowed(1), reused(17), launched(2)
Wrappers count: cct(2), ccc(2)
Messages:


Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - Jun 05 2023 :  12:02:48 PM  Show Profile  Reply with Quote
Thank you for the details, I have set up a test here with the same include directories, but of course, no sign of any problems.

I have emailed you about this.

case=149606

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

FAN
Senior Member

33 Posts

Posted - Jun 30 2023 :  03:06:46 AM  Show Profile  Reply with Quote

Is there an update on this issue? Code Inspection is still not working.

Go to Top of Page

FAN
Senior Member

33 Posts

Posted - Jul 03 2023 :  07:19:38 AM  Show Profile  Reply with Quote

Should we move this to a separate thread? This thread is about Find References not working, but now it is about Code Inspection not working.

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