Skip to content

Commit 51f166d

Browse files
committed
Java: Address review comments.
1 parent 106ba11 commit 51f166d

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

java/ql/src/Metrics/Summaries/TopJdkApis.qll

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/** Provides classes and predicates for working with Top JDK APIs. */
22

33
import java
4-
private import semmle.code.java.dataflow.FlowSummary
54
private import semmle.code.java.dataflow.internal.FlowSummaryImpl as FlowSummaryImpl
65
private import semmle.code.java.dataflow.ExternalFlow
76

@@ -298,16 +297,18 @@ class TopJdkApi extends Callable {
298297

299298
/** Holds if this API has a manual summary model. */
300299
private predicate hasManualSummary() {
301-
exists(SummarizedCallable sc | sc.asCallable() = this and sc.hasManualModel())
300+
exists(FlowSummaryImpl::Public::SummarizedCallable sc |
301+
sc.asCallable() = this and sc.hasManualModel()
302+
)
302303
}
303304

304-
/** Holds if this API has a manual neutral model. */
305-
private predicate hasManualNeutral() {
306-
this.(FlowSummaryImpl::Public::NeutralCallable).hasManualModel()
305+
/** Holds if this API has a manual neutral summary model. */
306+
private predicate hasManualNeutralSummary() {
307+
this.(FlowSummaryImpl::Public::NeutralSummaryCallable).hasManualModel()
307308
}
308309

309310
/** Holds if this API has a manual MaD model. */
310-
predicate hasManualMadModel() { this.hasManualSummary() or this.hasManualNeutral() }
311+
predicate hasManualMadModel() { this.hasManualSummary() or this.hasManualNeutralSummary() }
311312
/*
312313
* Note: the following top JDK APIs are not modeled with MaD:
313314
* `java.lang.Runnable#run()`: specialised lambda flow

0 commit comments

Comments
 (0)