Skip to content
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

FP: NP_METHOD_PARAMETER_TIGHTENS_ANNOTATION on constructors #164

Closed
shevek opened this issue Jul 26, 2017 · 1 comment
Closed

FP: NP_METHOD_PARAMETER_TIGHTENS_ANNOTATION on constructors #164

shevek opened this issue Jul 26, 2017 · 1 comment

Comments

@shevek
Copy link

shevek commented Jul 26, 2017

class Base {
Base(@CheckForNull Object x) {}
}

class Derived extends Base {
Derived(@Nonnull Object x) { super(x); }
}

This should NOT generate a NP_METHOD_PARAMETER_TIGHTENS_ANNOTATION because there's no way to access the constructor of Derived as a virtual method on Base. That warning is only valid for instance methods.

@iloveeclipse
Copy link
Member

This project continues development in a new home: https://github.com/spotbugs/spotbugs/

Please do not open new issues here anymore!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants