File: Bug2.java

package info (click to toggle)
checker-framework-java 3.2.0%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 22,840 kB
  • sloc: java: 145,910; xml: 839; sh: 518; makefile: 401; perl: 26
file content (26 lines) | stat: -rw-r--r-- 877 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import java.io.Serializable;
import java.util.AbstractMap;
import java.util.concurrent.ConcurrentMap;
import java.util.concurrent.locks.ReentrantLock;

@SuppressWarnings("") // Just check for crashes.
public class Bug2 {

    public <C, D> ConcurrentMap<C, D> makeMap() {
        return Bug2.create(this);
    }

    static <A, B> MyMap<A, B, ? extends MyMap.MyEntry<A, B, ?>, ?> create(Bug2 builder) {
        throw new RuntimeException();
    }

    abstract static class MyMap<
                    E, F, G extends MyMap.MyEntry<E, F, G>, H extends MyMap.MyLock<E, F, G, H>>
            extends AbstractMap<E, F> implements ConcurrentMap<E, F>, Serializable {

        interface MyEntry<I, J, K extends MyEntry<I, J, K>> {}

        abstract static class MyLock<L, M, N extends MyEntry<L, M, N>, O extends MyLock<L, M, N, O>>
                extends ReentrantLock {}
    }
}