Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 "Add include" doesn't care about ambiguity

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
Holger Gothan Posted - Dec 13 2018 : 05:53:11 AM
My Projects are all on drive E:.
Sometimes it happens that "add include" inserts not "..\..\global\myfile.h" but
"D:\Projects\global\myfile.h"

On drive D I have some old Version of my Project.
Sometimes I open some older version of one file from drive D:.
I think that's why VA is learning about D:.

Similar Problem:
My Solutions consits of 150 Projects.
Sometimes I use the same function name in different Project.
Sometimes it happens that "add include" inserts not "..\..\global\myfile.h" but
"..\..\OtherProject\myfile.h"

So I have to recheck every time I use "add include". Which i a bit annoying.


I think VA should prefere files on the same drive so that my first case never occurs.
I think in second case VA should ask.

Regards, Holger Gothan.

3   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Dec 17 2018 : 07:18:12 AM
Apologies, I should have explained my thinking there a bit more clearly.

The idea behind case=100831 is the situation where there are two (or more) matching header files, and each header file is in a different project in the solution. This can happen when the same class name is used more than once in a large solution. This change has the useful side effect of also ensuring the same drive letter, assuming that the rest of the files in the same project are on the same drive.

So instead of having a "narrow" check of just the drive letter, we have a more general check that helps with several different situations.
Holger Gothan Posted - Dec 17 2018 : 04:29:05 AM
Just one remark for the "drive letter problem"
Why asking the current project and not the current file?
Should be even more general.

feline Posted - Dec 13 2018 : 10:58:58 AM
There are a couple of changes to Add Include that we are looking to make at some point, and both should help here. First, if there is more than one candidate header file, VA will ask which one you want to include:

case=67573

For the other drive letter, we are also looking to have VA prefer the header file in the active project, if there is one. This should have the same effect as preferring the current drive letter, and also be a bit more general:

case=100831

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