|
Java example source code file (InferenceTest6.java)
The InferenceTest6.java Java example source code/* * @test /nodynamiccopyright/ * @bug 8003280 8016177 * @summary Add lambda tests * Missing cast to SAM type that causes type inference to not work. * @compile -XDrawDiagnostics InferenceTest6.java */ import java.util.*; public class InferenceTest6 { public static void main(String[] args) { InferenceTest6 test = new InferenceTest6(); test.method1(n -> {}); test.method1((SAM1<String>)n -> {}); test.method1((SAM1<Integer>)n -> {n++;}); test.method1((SAM1<Comparator Other Java examples (source code examples)Here is a short list of links related to this Java InferenceTest6.java source code file: |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.