Skip to content

Commit 934a455

Browse files
authored
Apply suggestions from code review
Update qldoc.
1 parent 8554263 commit 934a455

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

java/ql/lib/semmle/code/java/Member.qll

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -341,9 +341,8 @@ class Callable extends StmtParent, Member, @callable {
341341
}
342342

343343
/**
344-
* Holds if the given type is public and not a nested type.
345-
* If the given type is a nested type, holds if its enclosing type
346-
* is also public.
344+
* Holds if the given type is public and, if it is a nested type, that all of
345+
* its enclosing types are public as well.
347346
*/
348347
private predicate veryPublic(RefType t) {
349348
t.isPublic() and
@@ -358,8 +357,10 @@ class SrcCallable extends Callable {
358357
SrcCallable() { this.isSourceDeclaration() }
359358

360359
/**
361-
* Holds if this callable is effectively `public`, meaning that it can be
362-
* called outside the codebase.
360+
* Holds if this callable is effectively public in the sense that it can be
361+
* called from outside the codebase. This means either a `public` callable on
362+
* a sufficiently public type or a `protected` callable on a sufficiently
363+
* public non-`final` type.
363364
*/
364365
predicate isEffectivelyPublic() {
365366
exists(RefType t | t = this.getDeclaringType() |

0 commit comments

Comments
 (0)