jdk-24/test/langtools/tools/javac/4980495/std/NonStatic2StaticImportClash.java
Jan Lahoda 9bb2c5a0b3 8133616: compiler error messages for dup single type, single static import switched
When reporting clashing imports, use the (non-)staticness of the original import to generate the error message.

Reviewed-by: mcimadamore
2017-11-27 19:29:00 +01:00

15 lines
428 B
Java

/*
* @test /nodynamiccopyright/
* @bug 7101822 8133616
* @summary Check the when clashing types are imported through an ordinary and static import,
* the compile-time error is properly reported.
* @compile/fail/ref=NonStatic2StaticImportClash.out -XDrawDiagnostics NonStatic2StaticImportClash.java p1/A1.java p2/A2.java
*
*/
import static p1.A1.f;
import p2.A2.f;
public class NonStatic2StaticImportClash {
}