File: StaticInvokeSimple.java

package info (click to toggle)
libnb-javaparser-java 9%2B2018-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster
  • size: 65,172 kB
  • sloc: java: 440,096; xml: 6,359; sh: 865; makefile: 314
file content (14 lines) | stat: -rw-r--r-- 525 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* @test /nodynamiccopyright/
 * @bug 8037385
 * @summary Must not allow static interface method invocation in legacy code
 * @compile -source 8 -Xlint:-options StaticInvokeSimple.java
 * @compile/fail/ref=StaticInvokeSimple7.out -source 7 -Xlint:-options -XDrawDiagnostics StaticInvokeSimple.java
 * @compile/fail/ref=StaticInvokeSimple6.out -source 6 -Xlint:-options -XDrawDiagnostics StaticInvokeSimple.java
 */
import java.util.stream.Stream;

class StaticInvokeSimple {
    void test() {
        Stream.empty();
    }
}