From 26f6e93446e211a7c4bdc97871128d7877aecea4 Mon Sep 17 00:00:00 2001 From: paltherr Date: Tue, 30 Sep 2003 16:32:08 +0000 Subject: - Modified method proxy to compare enclFun of o... - Modified method proxy to compare enclFun of owners instead of owners directly. This solves bug 167. --- sources/scalac/transformer/LambdaLiftPhase.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sources') diff --git a/sources/scalac/transformer/LambdaLiftPhase.java b/sources/scalac/transformer/LambdaLiftPhase.java index eb3bb40d04..202508aef3 100644 --- a/sources/scalac/transformer/LambdaLiftPhase.java +++ b/sources/scalac/transformer/LambdaLiftPhase.java @@ -126,15 +126,15 @@ public class LambdaLiftPhase extends Phase implements Kinds, Modifiers { */ Symbol proxy(Symbol fv, Symbol owner) { if (global.debug) - global.log("proxy " + fv + " of " + fv.owner() + " in " + LambdaLift.asFunction(owner)); + global.log("proxy " + fv + " of " + fv.owner() + " in " + LambdaLift.enclFun(owner)); Symbol o = owner; while (o.kind != NONE) { if (global.debug) - global.log("looking in " + LambdaLift.asFunction(o) + " " + + global.log("looking in " + LambdaLift.enclFun(o) + " " + ArrayApply.toString(o.typeParams())); - Symbol fowner = LambdaLift.asFunction(o); + Symbol fowner = LambdaLift.enclFun(o); if (fowner.isMethod()) { - if (fv.owner() == fowner) return fv; + if (LambdaLift.enclFun(fv.owner()) == fowner) return fv; Type ft = (fowner.isUpdatedAt(this)) ? fowner.nextType() : fowner.type(); Symbol[] ownerparams = fv.isType() ? ft.typeParams() -- cgit v1.2.3