We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
outermost
1 parent 77f65f8 commit 33178b0Copy full SHA for 33178b0
compiler/src/dotty/tools/dotc/util/SourcePosition.scala
@@ -61,6 +61,9 @@ extends interfaces.SourcePosition with Showable {
61
def focus : SourcePosition = withSpan(span.focus)
62
def toSynthetic: SourcePosition = withSpan(span.toSynthetic)
63
64
+ def outermost: SourcePosition =
65
+ if outer == null || outer == NoSourcePosition then this else outer.outermost
66
+
67
override def toString: String =
68
s"${if (source.exists) source.file.toString else "(no source)"}:$span"
69
0 commit comments