Skip to content

Commit 1444622

Browse files
committed
Cleanup imports and fix documentation
1 parent c0b6166 commit 1444622

File tree

2 files changed

+15
-12
lines changed

2 files changed

+15
-12
lines changed

compiler/src/dotty/tools/dotc/ast/TreeMapWithImplicits.scala

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,24 @@
1-
package dotty.tools.dotc
2-
package ast
1+
package dotty.tools.dotc.ast
32

4-
import core._
5-
import ast.Trees._
6-
import Contexts._
7-
import Symbols._
8-
import annotation.tailrec
3+
import dotty.tools.dotc.ast.Trees._
4+
import dotty.tools.dotc.core.Contexts._
5+
import dotty.tools.dotc.core.Flags._
6+
import dotty.tools.dotc.core.Symbols._
7+
import dotty.tools.dotc.core.TypeError
98

10-
/** A TreeMap that maintains the necessary infrastructore to support
9+
import scala.annotation.tailrec
10+
11+
/** A TreeMap that maintains the necessary infrastructure to support
1112
* contxtual implicit searches (type-scope implicits are supported anyway).
13+
*
14+
* This incudes impicits defined in scope as well as imported implicits.
1215
*/
13-
class TreeMapWithImplicits extends ast.tpd.TreeMap {
14-
import ast.tpd._
16+
class TreeMapWithImplicits extends tpd.TreeMap {
17+
import tpd._
1518

1619
protected def localCtx(tree: Tree)(implicit ctx: Context): FreshContext = {
1720
val sym = tree.symbol
18-
val owner = if (sym is Flags.PackageVal) sym.moduleClass else sym
21+
val owner = if (sym is PackageVal) sym.moduleClass else sym
1922
ctx.fresh.setTree(tree).setOwner(owner)
2023
}
2124

compiler/src/dotty/tools/dotc/transform/ReifyQuotes.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ class ReifyQuotes extends MacroTransform {
303303
}
304304
)
305305
}
306-
/* Lambdas are generated outside the quote that is beeing reified (i.e. in outer.rctx.owner).
306+
/* Lambdas are generated outside the quote that is beeing reified (i.e. in outer.owner).
307307
* In case the case that level == -1 the code is not in a quote, it is in an inline method,
308308
* hence we should take that as owner directly.
309309
*/

0 commit comments

Comments
 (0)