-
Notifications
You must be signed in to change notification settings - Fork 139
Added UsageInspectionSuppresions for UnityEditor.Build.* #1167
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added UsageInspectionSuppresions for UnityEditor.Build.* #1167
Conversation
Thanks for the contribution, unfortunately, this is not the correct approach. The A more appropriate approach would be to add this directly to case IProperty when IsOrderedCallbackMember():
flags = ImplicitUseKindFlags.Access;
return true; and something similar for methods. The implementation check would probably need to check the method or property's |
resharper/resharper-unity/src/CSharp/Daemon/UsageChecking/UsageInspectionsSuppressor.cs
Outdated
Show resolved
Hide resolved
This solution might not work with different Unity versions in this form. I'm not sure how to test that however, any suggestions? |
Why do you think it might not work with other Unity versions? |
resharper/resharper-unity/src/CSharp/Daemon/UsageChecking/UsageInspectionsSuppressor.cs
Show resolved
Hide resolved
resharper/resharper-unity/src/CSharp/Daemon/UsageChecking/UsageInspectionsSuppressor.cs
Outdated
Show resolved
Hide resolved
{ | ||
throw new System.NotImplementedException(); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add another case where the interface is being implicitly implemented via a base class, e.g.
public abstract class Base : IPostprocessBuild
{
// …
public abstract void OnPostProcessBuild();
}
and
public class Derived : Base
{
public override void OnPostProcessBuild(…) { }
}
This should also help check if we can short circuit the type check.
resharper/resharper-unity/src/CSharp/Daemon/UsageChecking/UsageInspectionsSuppressor.cs
Outdated
Show resolved
Hide resolved
resharper/resharper-unity/src/CSharp/Daemon/UsageChecking/UsageInspectionsSuppressor.cs
Outdated
Show resolved
Hide resolved
Oh yeah, and can you add an "added" line in the |
Where are the plugin.xml and the resharper-unity.nuspec located? |
Simplified inheritance check of implicitly used interfaces Merged switch cases
LGTM |
Fixes #686
All the interfaces in UnityEditor.Build implement the IOrderedCallback interface however I could not figure out how to make the callbackOrder property implicitly used.