File: T4757416.java

package info (click to toggle)
libnb-javaparser-java 9%2B2018-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 65,320 kB
  • sloc: java: 440,096; xml: 6,359; sh: 865; makefile: 314
file content (17 lines) | stat: -rw-r--r-- 464 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/*
 * @test /nodynamiccopyright/
 * @bug 4756416
 * @summary generics: erasure clash not detected
 * @author gafter
 *
 * @compile/fail/ref=T4757416.out -XDrawDiagnostics   T4757416.java
 */

class T4756416 {
    static class C<A> { A id ( A x) { return x; } }
    interface I<A> { A id(A x); }
    static class D extends C<String> implements I<Integer> {
        public String id(String x) { return x; }
        public Integer id(Integer x) { return x; }
    }
}