Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 343718

Summary: [compiler] Qualified parameterized allocation expressions rejected incorrectly.
Product: [Eclipse Project] JDT Reporter: Srikanth Sankaran <srikanth_sankaran>
Component: CoreAssignee: Srikanth Sankaran <srikanth_sankaran>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3 CC: maxime_daniel, Olivier_Thomann
Version: 3.7   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard: stalebug

Description Srikanth Sankaran CLA 2011-04-25 03:01:03 EDT
The following program elicits just one error from
javac7 (b137) while it elicits two errors from
JDK5,6 and from eclipse. This difference needs to
be investigated.


public class X<T> {
	class Y<K>  {
	}
	X<String>.Y<Integer> xy = new X<String>.Y<Integer>(); // <<<--- HERE 
}

class Z {
	X<String>.Y<Integer> xy = new X<String>.Y<Integer>();
}
Comment 1 Srikanth Sankaran CLA 2011-05-24 20:37:25 EDT
*** Bug 236243 has been marked as a duplicate of this bug. ***
Comment 2 Srikanth Sankaran CLA 2012-01-11 07:28:41 EST
(In reply to comment #0)
> The following program elicits just one error from
> javac7 (b137) while it elicits two errors from
> JDK5,6 and from eclipse. This difference needs to
> be investigated.
> 
> 
> public class X<T> {
>     class Y<K>  {
>     }
>     X<String>.Y<Integer> xy = new X<String>.Y<Integer>(); // <<<--- HERE 

That doesn't sound right, how can a compiler guarantee that the
enclosing instance is of suitable type here ?

See also https://bugs.eclipse.org/bugs/show_bug.cgi?id=321185

Needs further study, Moving it out of M5 plan.
Comment 3 Eclipse Genie CLA 2020-09-11 13:44:13 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 4 Eclipse Genie CLA 2022-09-24 15:55:19 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.