You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: compiler/src/dotty/tools/dotc/transform/YCheckPositions.scala
+5-4Lines changed: 5 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -28,10 +28,11 @@ class YCheckPositions extends Phase {
28
28
// Check current context is correct
29
29
assert(ctx.source == sources.head)
30
30
if (!tree.isEmpty &&!tree.isInstanceOf[untpd.TypedSplice] &&!tree.isInstanceOf[Inlined] && ctx.typerState.isGlobalCommittable)
31
-
if (!tree.isType) { // TODO also check types, currently we do not add Inlined(EmptyTree, _, _) for types. We should.
31
+
if!tree.isType // TODO also check types, currently we do not add Inlined(EmptyTree, _, _) for types. We should.
32
+
&&!tree.symbol.is(InlineProxy) // TODO check inline proxies (see tests/tun/lst)
33
+
then
32
34
valcurrentSource= sources.head
33
-
assert(tree.source == currentSource, i"wrong source set for $tree # ${tree.uniqueId} of ${tree.getClass}, set to ${tree.source} but context had $currentSource")
34
-
}
35
+
assert(tree.source == currentSource, i"wrong source set for $tree # ${tree.uniqueId} of ${tree.getClass}, set to ${tree.source} but context had $currentSource\n${tree.symbol.flagsString}")
35
36
36
37
// Recursivlely check children while keeping track of current source
37
38
tree match {
@@ -42,7 +43,7 @@ class YCheckPositions extends Phase {
if (!isMacro(call)) // FIXME macro implementations can drop Inlined nodes. We should reinsert them after macro expansion based on the positions of the trees
0 commit comments