Skip to content

Commit 6d58dd2

Browse files
committed
Java: Update expected test output
1 parent 3da73b9 commit 6d58dd2

File tree

2 files changed

+2
-10
lines changed
  • java/ql/test/library-tests

2 files changed

+2
-10
lines changed

java/ql/test/library-tests/dataflow/callback-dispatch/A.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -151,15 +151,7 @@ void foo2() {
151151

152152
forEach(new Object[] {source(16)}, x -> sink(x)); // $ flow=16
153153

154-
// Spurious flow from 17 is reasonable as it would likely
155-
// also occur if the lambda body was inlined in a for loop.
156-
// It occurs from the combination of being able to observe
157-
// the side-effect of the callback on the other argument and
158-
// being able to chain summaries that update/read arguments,
159-
// e.g. fluent apis.
160-
// Spurious flow from 18 is due to not matching call targets
161-
// in a return-from-call-to-enter-call flow sequence.
162-
forEach(new Object[2][], xs -> { sink(xs[0]); xs[0] = source(17); }); // $ SPURIOUS: flow=17 flow=18
154+
forEach(new Object[2][], xs -> { sink(xs[0]); xs[0] = source(17); });
163155

164156
Object[][] xss = new Object[][] { { null } };
165157
forEach(xss, x -> {x[0] = source(18);});

java/ql/test/library-tests/frameworks/stream/Test.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,7 @@ public void test() throws Exception {
436436
sink(y); // $ hasValueFlow=reduce_3 hasValueFlow=reduce_4 hasValueFlow=reduce_5
437437
return source("reduce_5");
438438
});
439-
sink(out); // $ hasValueFlow=reduce_4 hasValueFlow=reduce_5 SPURIOUS: hasValueFlow=reduce_3
439+
sink(out); // $ hasValueFlow=reduce_4 hasValueFlow=reduce_5
440440
}
441441
{
442442
// "java.util.stream;Stream;true;reduce;(Object,BiFunction,BinaryOperator);;Argument[0];ReturnValue;value"

0 commit comments

Comments
 (0)