| Priority |
Normal |
| Type | Bug |
| State | Fixed |
| Assignee | Alexey Kudravtsev |
| Subsystem | Editor. Error Highlighting |
| Affected versions |
No affected versions
|
| Fixed in |
No fix versions
|
| Fixed in build |
Next build |
| Build |
7364
|
| Fixed in build |
7599
|
IDEA-42064 |
good code red: inheriting from raw type: "attempting to use incompatible return type" |
|
|
Three indications:
1. IDEA behaves differently for "MostDerived extends Derived extends Base" (red) and "MostDerived extends Base" (green). I can't think of an explanation for that other than there's a bug.
2. It also compiles fine when I switch to eclipse compiler.
3. From JLS 4.8 "Raw Types" I read that the inherited method "elements" from Base has the raw return type "List" that is overridden with "List<MostDerived>". According to 4.10.2, List<MostDerived> is a subtype of the raw type List, so the overriding is correct.