Thu, 10 Oct 2013 14:58:04 +0200
8001931: The new build system whitespace cleanup
Reviewed-by: tbell, simonis, erikj
aoqi@0 | 1 | /* |
aoqi@0 | 2 | * @test /nodynamiccopyright/ |
aoqi@0 | 3 | * @bug 8003280 |
aoqi@0 | 4 | * @summary Add lambda tests |
aoqi@0 | 5 | * speculative cache contents are overwritten by deferred type-checking of nested stuck expressions |
aoqi@0 | 6 | * @compile/fail/ref=MostSpecific07.out -XDrawDiagnostics MostSpecific07.java |
aoqi@0 | 7 | */ |
aoqi@0 | 8 | import java.util.*; |
aoqi@0 | 9 | |
aoqi@0 | 10 | class MostSpecific07 { |
aoqi@0 | 11 | |
aoqi@0 | 12 | interface Predicate<X, Y> { |
aoqi@0 | 13 | Y accept(X x); |
aoqi@0 | 14 | } |
aoqi@0 | 15 | |
aoqi@0 | 16 | interface VoidMapper { |
aoqi@0 | 17 | void accept(); |
aoqi@0 | 18 | } |
aoqi@0 | 19 | |
aoqi@0 | 20 | interface ExtPredicate<X, Y> extends Predicate<X, Y> { } |
aoqi@0 | 21 | |
aoqi@0 | 22 | void test(boolean cond, ArrayList<String> als, VoidMapper vm) { |
aoqi@0 | 23 | m(u -> ()->{}, als, als, vm); |
aoqi@0 | 24 | m((u -> ()->{}), als, als, vm); |
aoqi@0 | 25 | m(cond ? u -> ()->{} : u -> ()->{}, als, als, vm); |
aoqi@0 | 26 | } |
aoqi@0 | 27 | |
aoqi@0 | 28 | <U, V> U m(Predicate<U, V> p, List<U> lu, ArrayList<U> au, V v) { return null; } |
aoqi@0 | 29 | |
aoqi@0 | 30 | <U, V> U m(ExtPredicate<U, V> ep, ArrayList<U> au, List<U> lu, V v) { return null; } |
aoqi@0 | 31 | } |