File tree Expand file tree Collapse file tree 2 files changed +1922
-3
lines changed
compiler/src/dotty/tools/dotc Expand file tree Collapse file tree 2 files changed +1922
-3
lines changed Original file line number Diff line number Diff line change @@ -1046,9 +1046,9 @@ class Inliner(val call: tpd.Tree)(using Context):
1046
1046
new TreeAccumulator [List [Symbol ]] {
1047
1047
private var level = - 1
1048
1048
override def apply (syms : List [Symbol ], tree : tpd.Tree )(using Context ): List [Symbol ] =
1049
- if ( level != - 1 ) foldOver(syms, tree)
1049
+ if level != - 1 then foldOver(syms, tree)
1050
1050
else tree match {
1051
- case tree : RefTree if level == - 1 && tree.symbol.isDefinedInCurrentRun && ! tree.symbol.isLocal =>
1051
+ case tree : RefTree if tree.symbol.isDefinedInCurrentRun && ! tree.symbol.isLocal =>
1052
1052
foldOver(tree.symbol :: syms, tree)
1053
1053
case Quoted (body) =>
1054
1054
level += 1
@@ -1062,7 +1062,7 @@ class Inliner(val call: tpd.Tree)(using Context):
1062
1062
level -= 1
1063
1063
try apply(syms, body)
1064
1064
finally level += 1
1065
- case TypeApply (fun, _) if level == - 1 =>
1065
+ case TypeApply (fun, _) =>
1066
1066
apply(syms, fun)
1067
1067
case _ =>
1068
1068
foldOver(syms, tree)
You can’t perform that action at this time.
0 commit comments