mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
Merge pull request #1022 from yh-semmle/java/dead-code-override
Java: respect override annotations in `java/unused-parameter`
This commit is contained in:
@@ -296,6 +296,8 @@ class RootdefCallable extends Callable {
|
||||
// Methods that are the target of a member reference need to implement
|
||||
// the exact signature of the resulting functional interface.
|
||||
exists(MemberRefExpr mre | mre.getReferencedCallable() = this)
|
||||
or
|
||||
this.getAnAnnotation() instanceof OverrideAnnotation
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user