Skip to content

Commit 9891b41

Browse files
committed
Java: Add toString for new ContentApprox elements
1 parent c71898c commit 9891b41

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

java/ql/lib/semmle/code/java/dataflow/internal/DataFlowPrivate.qll

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -757,6 +757,12 @@ class ContentApprox extends TContentApprox {
757757
or
758758
this = TSyntheticFieldApproxContent() and
759759
result = "approximated synthetic field"
760+
or
761+
this = TLambdaReturnContentApprox(_) and
762+
result = "<lambda-return>"
763+
or
764+
this = TLambdaArgumentApprox(_, _) and
765+
result = "<lambda-argument>"
760766
}
761767
}
762768

java/ql/lib/semmle/code/java/dataflow/internal/DataFlowUtil.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,7 @@ class LambdaArgumentContent extends Content, TLambdaArgumentContent {
378378

379379
override DataFlowType getType() { result = getErasedRepr(m.getParameter(pos).getType()) }
380380

381-
override string toString() { result = "<lambda-argument>" + pos.toString() }
381+
override string toString() { result = "<lambda-argument> " + pos.toString() }
382382
}
383383

384384
/**

0 commit comments

Comments
 (0)