blob: 0180d3d6345576988da9d80c488e26c99c4b6caf (
plain) (
tree)
|
|
package test;
object Main extends Application {
class Global {
case class Template(x : Int, y : Int) {
Console.println("outer: " + Global.this);
}
}
trait Contexts requires Analyzer {
val xxx : global.Template = {
assert(globalInit0 != null);
globalInit0.Template(10, 20);
}
}
abstract class Analyzer extends Contexts {
type Global <: Main.Global;
final val global : Global = globalInit;
def globalInit : Global;
final def globalInit0 = globalInit.asInstanceOf[global.type];
}
object global0 extends Global {
object analyzer extends Analyzer {
type Global = global0.type;
override def globalInit = global0;
}
}
Console.println(global0.analyzer.xxx);
}
|