Aladdin - Scala Bugtracking
[#53] project: compiler priority: medium category: bug
submitter assigned to status date submitted
Philippe Martin fixed 2003-07-07 13:31:48.0
subject crash in lambdalift
code
object bug {
  def foobar[c]: Int = {
    class Foo { def foo: Bar = new Bar(); }
    class Bar { def bar: c   = bar; }
    0
  }
}
what happened
Exception in thread "main" scalac.ApplicationError: poly type required: MethodType([],TypeRef(ThisType(),b\
ug.foobar.Bar$0,[]))
        at scalac.ast.TreeGen.TypeApply(TreeGen.java:397)
        at scalac.ast.TreeGen.TypeApply(TreeGen.java:401)
        at scalac.transformer.LambdaLift.transform(LambdaLift.java:403)
        at scalac.ast.Transformer.transform(Transformer.java:249)
        at scalac.ast.Transformer.transform(Transformer.java:140)
        at scalac.transformer.OwnerTransformer.transform(OwnerTransformer.java:138)
        at scalac.transformer.LambdaLift.transform(LambdaLift.java:422)
        ...
what expected no crash
[back to overview]
Changes of this bug report
Martin  edited on  2003-07-08 15:13:24.0