8000 Overlay: Add manual Java overlay annotations & discard predicates by kaspersv · Pull Request #19813 · github/codeql · GitHub
[go: up one dir, main page]

Skip to content

Overlay: Add manual Java overlay annotations & discard predicates #19813

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

Merged
merged 6 commits into from
Jun 30, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Java: Allow methods with empty bodies for overlay
  • Loading branch information
kaspersv committed Jun 24, 2025
commit 0ee6a78a4a760e01d50f8400ce086128b60224c9
8 changes: 7 additions & 1 deletion java/ql/lib/semmle/code/java/Member.qll
Original file line number Diff line number Diff line change
Expand Up @@ -624,7 +624,13 @@ class SrcMethod extends Method {
then implementsInterfaceMethod(result, this)
else result.getASourceOverriddenMethod*() = this
) and
(exists(result.getBody()) or result.hasModifier("native"))
(
// We allow empty method bodies for the local overlay variant to allow
// calls to methods only fully extracted in base.
isOverlay() or
exists(result.getBody()) or
result.hasModifier("native")
)
}
}

Expand Down
Loading
0