Bug 110788 - Should not be able to mark a class as implementing multiple parameterizations of a generic type using decp
Summary: Should not be able to mark a class as implementing multiple parameterizations...
Status: RESOLVED FIXED
Alias: None
Product: AspectJ
Classification: Tools
Component: Compiler (show other bugs)
Version: DEVELOPMENT   Edit
Hardware: PC Windows XP
: P2 normal (vote)
Target Milestone: 1.5.0 M4   Edit
Assignee: Andrew Clement CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-27 08:51 EDT by Andrew Clement CLA
Modified: 2005-09-30 08:16 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Clement CLA 2005-09-27 08:51:16 EDT
This program:
interface A<T> {}

interface B<T> extends A<T> {}

class C implements A<String> {}

class D extends C implements B<Number>{}

produces:

K:\ws\aspectj_ws3\tests\bugs150\pr110307>ajc MultipleParameterizations1.java -1.5
K:\ws\aspectj_ws3\tests\bugs150\pr110307\MultipleParameterizations1.java:7 
  [error] The interface A cannot be implemented more than once with different
   arguments: A<String> and A<Number>
class D extends C implements B<Number>{}


This program:

interface A<T> {}

interface B<T> extends A<T> {}

class C implements A<String> {
}

class D extends C {
}

aspect X {
  declare parents: D implements B<Number>;
}


compiles fine - it should report the same error.
Comment 1 Andrew Clement CLA 2005-09-28 05:50:30 EDT
Multiple cases of this created as testcases and fix checked in.  waiting on
build before closing.
Comment 2 Andrew Clement CLA 2005-09-30 08:16:31 EDT
fix available.