new inference: provide diagnostics on failed inference (strict subtyping constraints); don't resolve vars before incorporate - this way captures won't be opened too early

This commit is contained in:
Anna Kozlova
2015-11-24 10:30:21 +01:00
parent 24bfcbcd27
commit 138bd5a034
8 changed files with 24 additions and 21 deletions
@@ -87,7 +87,7 @@ class CaptureTest {
}
void foo (Class<? extends Emum<CaptureTest>> clazz) {
<error descr="Inferred type 'capture<? extends CaptureTest.Emum<CaptureTest>>' for type parameter 'T' is not within its bound; should extend 'CaptureTest.Emum<capture<? extends CaptureTest.Emum<CaptureTest>>>'">Emum.valueOf(clazz, "CCC")</error>;
<error descr="Inferred type 'java.lang.Object' for type parameter 'T' is not within its bound; should extend 'CaptureTest.Emum<java.lang.Object>'">Emum.valueOf(clazz, "CCC")</error>;
}
}