Skip to content

Commit cc47ec1

Browse files
committed
callSiteTyper and TypingTransformers are gone
1 parent 7e72ef0 commit cc47ec1

File tree

2 files changed

+1
-13
lines changed

2 files changed

+1
-13
lines changed

src/main/scala/scala/async/internal/AsyncMacro.scala

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ object AsyncMacro {
1010
new AsyncMacro { self =>
1111
val c: scala.reflect.macros.Context { val universe: global.type } = c0.asInstanceOf[scala.reflect.macros.Context { val universe: global.type }]
1212
val global: powerContext.universe.type = powerContext.universe
13-
val callSiteTyper: global.analyzer.Typer = powerContext.callsiteTyper
1413
val macroApplication: global.Tree = c0.macroApplication.asInstanceOf[global.Tree]
1514
// This member is required by `AsyncTransform`:
1615
val asyncBase: AsyncBase = base
@@ -22,13 +21,11 @@ object AsyncMacro {
2221
}
2322

2423
private[async] trait AsyncMacro
25-
extends TypingTransformers
26-
with AnfTransform with TransformUtils with Lifter
24+
extends AnfTransform with TransformUtils with Lifter
2725
with ExprBuilder with AsyncTransform with AsyncAnalysis with LiveVariables {
2826

2927
val c: scala.reflect.macros.Context { val universe: global.type }
3028
val global: Global
31-
val callSiteTyper: global.analyzer.Typer
3229
val macroApplication: global.Tree
3330

3431
lazy val macroPos = macroApplication.pos.makeTransparent

src/main/scala/scala/async/internal/TransformUtils.scala

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -206,15 +206,6 @@ private[async] trait TransformUtils {
206206
}
207207
}
208208

209-
abstract class MacroTypingTransformer extends TypingTransformer(callSiteTyper.context.unit) {
210-
currentOwner = enclosingOwner
211-
curTree = EmptyTree
212-
213-
def currOwner: Symbol = currentOwner
214-
215-
localTyper = global.analyzer.newTyper(callSiteTyper.context.make(unit = callSiteTyper.context.unit))
216-
}
217-
218209
def transformAt(tree: Tree)(f: PartialFunction[Tree, (TypingTransformApi => Tree)]) = {
219210
typingTransform(tree)((tree, api) => {
220211
if (f.isDefinedAt(tree)) f(tree)(api)

0 commit comments

Comments
 (0)