find all occurrences of comparison with == in visual studio
Posted
by
Emiswelt
on Stack Overflow
See other posts from Stack Overflow
or by Emiswelt
Published on 2011-01-03T18:42:46Z
Indexed on
2011/01/03
18:53 UTC
Read the original article
Hit count: 160
Hi there
I made the mistake of using == for comparing IP addresses instead of using the equals() method of the IPAddress class in C#, which will result in the comparison of references instead of values. Since the solution I am currently working on is very large for a one-man project (> 100.000 lines of source code), I am very sure that I still have some of these wrong statements in my code.
Is there any possibility to tell Visual Studio to find all occurrences of == operations on a specific class for me, so that I can find and clean up the bugged comparisons?
with best regards, emi
© Stack Overflow or respective owner