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
 Feature Requests
 find assignment references
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

smacl
New Member

6 Posts

Posted - Sep 08 2016 :  05:04:12 AM  Show Profile  Reply with Quote
While one of the simpler tools, Find References is one I use very often. A great addition to this would be have an option to either filter or sort references by type, e.g. assignment, comparison, pass by value, pass by address etc.. The one I usually am looking for is where a variable is likely to be modified, where I'm interested in code that changes a variable rather than just reading its value. Thus if I'm looking for int A, currently I get lines such as

if (X==A) b();  // A doesn't change
A = X;  // A does change
f(A);  void f(int &A)  // A could change 
f(A);  void f(int A)  // A doesn't change
f(&A);  void f(int *A)  // A could change


It would be great to filter search for references based on whether A does, doesn't or might get changed.

accord
Whole Tomato Software

United Kingdom
3287 Posts

Posted - Sep 14 2016 :  6:23:02 PM  Show Profile  Reply with Quote
Are you aware of our current filtering methods?



You can filter by write and read references.

We're also considering to indicate lines where symbol might be modified in Find References Results list:

case=9955
Go to Top of Page

smacl
New Member

6 Posts

Posted - Sep 15 2016 :  02:42:27 AM  Show Profile  Reply with Quote
Wasn't aware of this, should have RTFM ;)
Go to Top of Page

smacl
New Member

6 Posts

Posted - Oct 08 2016 :  07:07:44 AM  Show Profile  Reply with Quote
quote:
Originally posted by accord

Are you aware of our current filtering methods? You can filter by write and read references.

We're also considering to indicate lines where symbol might be modified in Find References Results list:

case=9955



I've been using this feature now and find it great, but it does need an extra category for handling pass by reference cases, where the variable could get written to by a function it is passed to under another name, e.g.

void set(int &var, int value)
{
  var = value;
}

int x = 0;
set(x,1);  // VA lists this as a read, but it is actually a write


This problem also exists on certain operator overloads, such as CArchive::>> in MFC
Go to Top of Page

Mordachai
Tomato Guru

USA
224 Posts

Posted - Oct 12 2016 :  11:53:22 AM  Show Profile  Reply with Quote
I would also like this to be a 1st class "Find Assignments" or somesuch. I need that information about 50% of the time, and having to change the results filter to get at what I need is sub-optimal. "Find All References" + "Find all accessors" + "find all writers" would be really useful set of fly-outs - where the first one is the current impl., and the others just apply the correct initial filters.
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