File tree Expand file tree Collapse file tree 4 files changed +28
-0
lines changed
jbmc/regression/jbmc/lambda1 Expand file tree Collapse file tree 4 files changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -5,4 +5,12 @@ public static void test(Nondet nondet) {
5
5
Function <Integer , Integer > lambda = (z ) -> nondet .x + nondet .y + z ;
6
6
assert (lambda .apply (0 ) == 42 );
7
7
}
8
+ public static void testPrimitiveArray (int [] ints ) {
9
+ Function <Integer , Integer > lambda = (index ) -> ints [index ];
10
+ assert (lambda .apply (0 ) == 42 );
11
+ }
12
+ public static void testReferenceArray (Nondet [] nondets ) {
13
+ Function <Integer , Integer > lambda = (index ) -> nondets [index ].x ;
14
+ assert (lambda .apply (0 ) == 42 );
15
+ }
8
16
}
Original file line number Diff line number Diff line change
1
+ CORE
2
+ Nondet.class
3
+ --function Nondet.testPrimitiveArray --cp `../../../../scripts/format_classpath.sh . ../../../lib/java-models-library/target/core-models.jar`
4
+ line 10 assertion.*FAILURE$
5
+ ^EXIT=10$
6
+ ^SIGNAL=0$
7
+ --
8
+ --
9
+ Check that primitive arrays created by the object factory can be
10
+ captured by a lambda
Original file line number Diff line number Diff line change
1
+ CORE
2
+ Nondet.class
3
+ --function Nondet.testReferenceArray --cp `../../../../scripts/format_classpath.sh . ../../../lib/java-models-library/target/core-models.jar`
4
+ line 14 assertion.*FAILURE$
5
+ ^EXIT=10$
6
+ ^SIGNAL=0$
7
+ --
8
+ --
9
+ Check that reference arrays created by the object factory can be
10
+ captured by a lambda
You can’t perform that action at this time.
0 commit comments