From 6afa119232f2c3dac66489b5988d7f62a8e882df Mon Sep 17 00:00:00 2001 From: Eugene Burmako Date: Fri, 3 Jan 2014 02:09:36 +0300 Subject: [PATCH] a tiny stab at #14 --- .../org/scalalang/macroparadise/typechecker/Namers.scala | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugin/src/main/scala/org/scalalang/macroparadise/typechecker/Namers.scala b/plugin/src/main/scala/org/scalalang/macroparadise/typechecker/Namers.scala index 32230cba..451dc65e 100644 --- a/plugin/src/main/scala/org/scalalang/macroparadise/typechecker/Namers.scala +++ b/plugin/src/main/scala/org/scalalang/macroparadise/typechecker/Namers.scala @@ -533,7 +533,9 @@ trait Namers { // we have to skip two contexts: // 1) the Template context that hosts members // 2) the ImplDef context that hosts type params (and just them?) - else if (sym.owner.isClass) newTyper(context.outer.outer) + // upd. actually, i don't think we should skip the second context + // that doesn't buy us absolutely anything wrt robustness + else if (sym.owner.isClass) newTyper(context.outer) // expanding at block level => only allow to see outside of the block else newTyper(context.outer) ).asInstanceOf[ParadiseTyper]