changeset 7652:e24f6efedc1e

Bugfix to SerializedLambdaTest
author briangoetz
date Thu, 14 Mar 2013 18:00:24 -0400
parents c4d4cd1fc2ae
children 820040c10150
files test-ng/tests/org/openjdk/tests/java/lang/invoke/SerializedLambdaTest.java
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/test-ng/tests/org/openjdk/tests/java/lang/invoke/SerializedLambdaTest.java	Thu Mar 14 15:18:29 2013 -0400
+++ b/test-ng/tests/org/openjdk/tests/java/lang/invoke/SerializedLambdaTest.java	Thu Mar 14 18:00:24 2013 -0400
@@ -272,11 +272,11 @@
     //Test throwing away return type
     public void testDiscardReturnBound() throws IOException, ClassNotFoundException {
         List<String> list = new ArrayList<>();
-        Consumer<String> c = list::add;
+        Consumer<String> c = (Consumer<String> & Serializable) list::add;
         assertSerial(c, cc -> { assertTrue(cc instanceof Consumer); });
 
         AtomicLong a = new AtomicLong();
-        LongConsumer lc = a::addAndGet;
+        LongConsumer lc = (LongConsumer & Serializable) a::addAndGet;
         assertSerial(lc, plc -> { plc.accept(3); });
     }
 }