You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using recursive generics, for example, creating a self-reference, an incomprehensible warning is raised. When using simple non-recursive generics, there is no warning. Perhaps I do not understand something? Maybe this is an IDE bug?
Experiment.java
packageorg.lignium.experiment;
publicfinalclassExperiment {
privatestaticabstractclassRegion<RextendsRegion<R>> {
publicabstractRself();
}
privatestaticfinalclassCuboidRegionextendsRegion<CuboidRegion> {
@OverridepublicCuboidRegionself() {
returnthis;
}
}
publicstaticvoidmain(String[] arguments) {
// Warning at wildcard: Non-null type argument is expectedRegion<?> region = newCuboidRegion();
}
}
The warning you mention, Non-null type argument is expected, is produced by IntelliJ IDEA not the Nullness Checker. Since I can't reproduce the error, I can't say if it's an IntelliJ IDEA bug.
When using recursive generics, for example, creating a self-reference, an incomprehensible warning is raised. When using simple non-recursive generics, there is no warning. Perhaps I do not understand something? Maybe this is an IDE bug?
Experiment.java
package-info.java
The text was updated successfully, but these errors were encountered: