| [#266] | project: compiler | priority: high | category: bug | |
|---|---|---|---|---|
| submitter | assigned to | status | date submitted | |
| Martin | Philippe | fixed | 2004-01-05 12:44:35.0 | |
| subject | missing bridge method | |||
| code |
abstract class A {
type t;
abstract class P {
def f(x: t): unit;
}
}
abstract class A1 extends A {
def mkP: A1.this.P;
val in: t;
}
class B extends A {
type t = int;
class P1 extends B.this.P {
def f(x: int): unit = System.out.println(x + 1);
}
def mkP = new P1;
val in = 3;
}
object test with Executable {
val a: A1 = new A1 with B;
a.mkP.f(a.in);
} |
|||
| what happened | java test Exception in thread "main" java.lang.AbstractMethodError: B$P1$class.f(Ljava/lang/Object;)V at test$. |
|||
| what expected | A succesful run. It seems a bridge method is missing, because Erasure does not detect that B.P1.f overrides A.P.f. | |||
| [back to overview] | ||||
| Martin edited on 2004-01-05 17:40:07.0 |
| Philippe edited on 2004-01-07 18:49:12.0 |
|
Fixed by new version of |