Bug 113710 - Eclipse show an error for valid code
Summary: Eclipse show an error for valid code
Status: VERIFIED DUPLICATE of bug 112109
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.1.2   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-10-25 16:48 EDT by John Liu CLA
Modified: 2006-01-10 08:00 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Liu CLA 2005-10-25 16:48:07 EDT
The code below produces an error although the Java 5.0 compiler and 3.1 release 
of elcipse does not.

import java.awt.Graphics2D;
import java.awt.Shape;

public class TestClass<V extends DrawObject> {

   /** Base object for wrapping */
   protected V draw;

   /**
    * Draw the object with its attached text
    * 
    * @param graphics the graphics object to draw into
    */
   public void draw( Graphics2D graphics ) {
      draw.draw(graphics);
   }
}

abstract class DrawObject implements Drawable {

   protected void draw( Graphics2D graphics, Shape shape ) {
   }
}

interface Drawable {

   void draw( Graphics2D graphics );
}
Comment 1 Olivier Thomann CLA 2005-10-25 20:33:45 EDT
Closing as a duplicate of bug 112109.
Added org.eclipse.jdt.core.tests.compiler.regression.GenericTypeTest.test859

*** This bug has been marked as a duplicate of 112109 ***
Comment 2 Frederic Fusier CLA 2006-01-10 08:00:06 EST
Verified for 3.1.2 using build M20060109-1200.