| Summary: | [1.8][compiler] Various loose ends in Diamond inference implementation | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Srikanth Sankaran <srikanth_sankaran> |
| Component: | Core | Assignee: | Srikanth Sankaran <srikanth_sankaran> |
| Status: | VERIFIED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | jarthana, noopur_gupta, stephan.herrmann |
| Version: | 4.4 | ||
| Target Milestone: | BETA J8 | ||
| Hardware: | PC | ||
| OS: | Windows 7 | ||
| Whiteboard: | |||
| Bug Depends on: | |||
| Bug Blocks: | 427787 | ||
I should call out that these are issues in the existing (1.7) implementation carried over to 1.8. Fixed with this patch: http://git.eclipse.org/c/jdt/eclipse.jdt.core.git/commit/?h=BETA_JAVA8&id=0b27309efdaba54bffa19e81e0f1e5ae6f176884 Verified as working for Eclipse + Java 8 RC1 using Kepler SR2(RC4) + Eclipse Java Development Tools Patch for Java 8 Support (BETA) 1.0.0.v20140220-2054 using the test case changes. |
Using this CR as the home, I'll shortly release a patch that fixes a bunch of loose ends with the present synthetic static factory based <> inference. Many of these problems show up while building JRE8 from source zip. Basically, - Type variables from enclosing types are not handled correctly. - Rawness of enclosing type is lost (static nested generic class sees its outer as raw.) - Certain scenarios result in NPEs while diagnosing redundant type argument specification. - Outer rawness gets dropped during substitutions - Static factory method's return type is not encoded properly. These problems do not affect the most common scenarios, but are important enough to fix because these impact the inference in non so uncommon scenarios.