简体   繁体   English

查找分配给Int64属性的所有出现的Int32值。 参数或字段

[英]Find all occurrence of Int32 value assigned to Int64 property. parameter or field

I am in process of converting some DB fields from Int32 to Int64. 我正在将一些数据库字段从Int32转换为Int64。 My application needs to reflect that too. 我的应用程序也需要反映这一点。 But in a huge code base, I am trying to find all the occurrence where an int is assigned to my (now) properties 但是在庞大的代码库中,我试图查找将int分配给我(现在)属性的所有情况

long amount = resopnse.Value; /*Int32*/

While assignments like this don't generate any compilation error, I would like to go thru the entire chain and convert all the int values to long, which are being assigned to my (now) long fields. 尽管这样的分配不会产生任何编译错误,但我还是希望遍历整个链并将所有int值都转换为long值,这些值已分配给了我(现在)的long字段。

Is there a way to find all such assignments of int to a long member? 有没有办法找到所有这样的int分配给long成员?

You can try using ReSharper for visual studio to find them all (They have a trial version I bet) https://www.jetbrains.com/resharper/ 您可以尝试使用ReSharper for visual studio来查找所有内容(我敢打赌他们有一个试用版) https://www.jetbrains.com/resharper/ 在此处输入图片说明

Click on object browser of a int32 and find all usages. 单击int32的对象浏览器并找到所有用法。 Tons of other cool stuff resharper can do if you need help figuring it out let me know. 如果需要帮助,请给我一些其他有趣的东西。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM