From f36835638fd3fa17dc15d196f785524f5f6ac211 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Fournier?= Date: Fri, 20 Mar 2020 10:45:48 +0100 Subject: [PATCH] Add some scala tests --- .../lang/java/ast/AbstractJavaTreeDumpTest.kt | 18 - .../pmd/lang/java/ast/AstTreeDumpTests.kt | 20 - .../pmd/lang/java/ast/testdata/Bug1429.java | 22 - .../pmd/lang/java/ast/testdata/Bug1429.txt | 200 -- .../pmd/lang/scala/ast/ScalaParserTests.kt | 23 + .../pmd/lang/scala/ast/testdata/List.scala | 324 ++++ .../pmd/lang/scala/ast/testdata/List.txt | 1634 +++++++++++++++++ .../pmd/lang/scala/ast/testdata/package.scala | 22 + .../pmd/lang/scala/ast/testdata/package.txt | 90 + 9 files changed, 2093 insertions(+), 260 deletions(-) delete mode 100644 pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AbstractJavaTreeDumpTest.kt delete mode 100644 pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AstTreeDumpTests.kt delete mode 100644 pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.java delete mode 100644 pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.txt create mode 100644 pmd-scala/src/test/kotlin/net/sourceforge/pmd/lang/scala/ast/ScalaParserTests.kt create mode 100644 pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.scala create mode 100644 pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.txt create mode 100644 pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.scala create mode 100644 pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.txt diff --git a/pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AbstractJavaTreeDumpTest.kt b/pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AbstractJavaTreeDumpTest.kt deleted file mode 100644 index 5c517cf164..0000000000 --- a/pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AbstractJavaTreeDumpTest.kt +++ /dev/null @@ -1,18 +0,0 @@ -/* - * BSD-style license; for more info see http://pmd.sourceforge.net/license.html - */ - -package net.sourceforge.pmd.lang.java.ast - -import net.sourceforge.pmd.lang.ast.test.BaseTreeDumpTest -import net.sourceforge.pmd.lang.ast.test.SimpleNodePrinter -import net.sourceforge.pmd.lang.java.JavaParsingHelper -import net.sourceforge.pmd.util.treeexport.TreeRenderer - -abstract class AbstractJavaTreeDumpTest(printer: TreeRenderer = SimpleNodePrinter) - : BaseTreeDumpTest(printer = printer, extension = ".java") { - - override val parser: JavaParsingHelper = - JavaParsingHelper.WITH_PROCESSING.withResourceContext(javaClass, "testdata") -} - diff --git a/pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AstTreeDumpTests.kt b/pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AstTreeDumpTests.kt deleted file mode 100644 index ad0d611f91..0000000000 --- a/pmd-java/src/test/kotlin/net/sourceforge/pmd/lang/java/ast/AstTreeDumpTests.kt +++ /dev/null @@ -1,20 +0,0 @@ -/* - * BSD-style license; for more info see http://pmd.sourceforge.net/license.html - */ - -package net.sourceforge.pmd.lang.java.ast - -import org.junit.Test - -/** - * Compare a dump of a file against a saved baseline. - * - * @author Clément Fournier - */ -class AstTreeDumpTests : AbstractJavaTreeDumpTest() { - - @Test - fun testComplicatedLambda() = doTest("Bug1429") - - -} diff --git a/pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.java b/pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.java deleted file mode 100644 index 2f61b06e26..0000000000 --- a/pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.java +++ /dev/null @@ -1,22 +0,0 @@ -/* - * BSD-style license; for more info see http://pmd.sourceforge.net/license.html - */ - -public class Bug1429 { - public Set getAttributeTuples() { - return (Set) (this.attributes == null ? Collections. emptySet() : new HashSet( - CollectionUtils.collect(this.attributes.keySet(), new Transformer() { - @Override - public Object transform(final Object obj) { - final String key = (String) obj; - final String value = HGXLIFFTypeConfiguration.this.attributes.get(key); - - String result = key; - if (StringUtils.isNotEmpty(value)) { - result = result.concat(":").concat(value); - } - return result; - } - }))); - } -} diff --git a/pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.txt b/pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.txt deleted file mode 100644 index fa19d6bb63..0000000000 --- a/pmd-java/src/test/resources/net/sourceforge/pmd/lang/java/ast/testdata/Bug1429.txt +++ /dev/null @@ -1,200 +0,0 @@ -└─ CompilationUnit - └─ TypeDeclaration - └─ ClassOrInterfaceDeclaration - └─ ClassOrInterfaceBody - └─ ClassOrInterfaceBodyDeclaration - └─ MethodDeclaration - ├─ ResultType - │ └─ Type - │ └─ ReferenceType - │ └─ ClassOrInterfaceType - │ └─ TypeArguments - │ └─ TypeArgument - │ └─ ReferenceType - │ └─ ClassOrInterfaceType - ├─ MethodDeclarator - │ └─ FormalParameters - └─ Block - └─ BlockStatement - └─ Statement - └─ ReturnStatement - └─ Expression - └─ CastExpression - ├─ Type - │ └─ ReferenceType - │ └─ ClassOrInterfaceType - │ └─ TypeArguments - │ └─ TypeArgument - │ └─ ReferenceType - │ └─ ClassOrInterfaceType - └─ PrimaryExpression - └─ PrimaryPrefix - └─ Expression - └─ ConditionalExpression - ├─ EqualityExpression - │ ├─ PrimaryExpression - │ │ ├─ PrimaryPrefix - │ │ └─ PrimarySuffix - │ └─ PrimaryExpression - │ └─ PrimaryPrefix - │ └─ Literal - │ └─ NullLiteral - ├─ Expression - │ └─ PrimaryExpression - │ ├─ PrimaryPrefix - │ │ └─ Name - │ ├─ PrimarySuffix - │ │ └─ MemberSelector - │ │ └─ TypeArguments - │ │ └─ TypeArgument - │ │ └─ ReferenceType - │ │ └─ ClassOrInterfaceType - │ └─ PrimarySuffix - │ └─ Arguments - └─ PrimaryExpression - └─ PrimaryPrefix - └─ AllocationExpression - ├─ ClassOrInterfaceType - │ └─ TypeArguments - │ └─ TypeArgument - │ └─ ReferenceType - │ └─ ClassOrInterfaceType - └─ Arguments - └─ ArgumentList - └─ Expression - └─ PrimaryExpression - ├─ PrimaryPrefix - │ └─ Name - └─ PrimarySuffix - └─ Arguments - └─ ArgumentList - ├─ Expression - │ └─ PrimaryExpression - │ ├─ PrimaryPrefix - │ ├─ PrimarySuffix - │ ├─ PrimarySuffix - │ └─ PrimarySuffix - │ └─ Arguments - └─ Expression - └─ PrimaryExpression - └─ PrimaryPrefix - └─ AllocationExpression - ├─ ClassOrInterfaceType - ├─ Arguments - └─ ClassOrInterfaceBody - └─ ClassOrInterfaceBodyDeclaration - ├─ Annotation - │ └─ MarkerAnnotation - │ └─ Name - └─ MethodDeclaration - ├─ ResultType - │ └─ Type - │ └─ ReferenceType - │ └─ ClassOrInterfaceType - ├─ MethodDeclarator - │ └─ FormalParameters - │ └─ FormalParameter - │ ├─ Type - │ │ └─ ReferenceType - │ │ └─ ClassOrInterfaceType - │ └─ VariableDeclaratorId - └─ Block - ├─ BlockStatement - │ └─ LocalVariableDeclaration - │ ├─ Type - │ │ └─ ReferenceType - │ │ └─ ClassOrInterfaceType - │ └─ VariableDeclarator - │ ├─ VariableDeclaratorId - │ └─ VariableInitializer - │ └─ Expression - │ └─ CastExpression - │ ├─ Type - │ │ └─ ReferenceType - │ │ └─ ClassOrInterfaceType - │ └─ PrimaryExpression - │ └─ PrimaryPrefix - │ └─ Name - ├─ BlockStatement - │ └─ LocalVariableDeclaration - │ ├─ Type - │ │ └─ ReferenceType - │ │ └─ ClassOrInterfaceType - │ └─ VariableDeclarator - │ ├─ VariableDeclaratorId - │ └─ VariableInitializer - │ └─ Expression - │ └─ PrimaryExpression - │ ├─ PrimaryPrefix - │ │ └─ Name - │ ├─ PrimarySuffix - │ ├─ PrimarySuffix - │ ├─ PrimarySuffix - │ └─ PrimarySuffix - │ └─ Arguments - │ └─ ArgumentList - │ └─ Expression - │ └─ PrimaryExpression - │ └─ PrimaryPrefix - │ └─ Name - ├─ BlockStatement - │ └─ LocalVariableDeclaration - │ ├─ Type - │ │ └─ ReferenceType - │ │ └─ ClassOrInterfaceType - │ └─ VariableDeclarator - │ ├─ VariableDeclaratorId - │ └─ VariableInitializer - │ └─ Expression - │ └─ PrimaryExpression - │ └─ PrimaryPrefix - │ └─ Name - ├─ BlockStatement - │ └─ Statement - │ └─ IfStatement - │ ├─ Expression - │ │ └─ PrimaryExpression - │ │ ├─ PrimaryPrefix - │ │ │ └─ Name - │ │ └─ PrimarySuffix - │ │ └─ Arguments - │ │ └─ ArgumentList - │ │ └─ Expression - │ │ └─ PrimaryExpression - │ │ └─ PrimaryPrefix - │ │ └─ Name - │ └─ Statement - │ └─ Block - │ └─ BlockStatement - │ └─ Statement - │ └─ StatementExpression - │ ├─ PrimaryExpression - │ │ └─ PrimaryPrefix - │ │ └─ Name - │ ├─ AssignmentOperator - │ └─ Expression - │ └─ PrimaryExpression - │ ├─ PrimaryPrefix - │ │ └─ Name - │ ├─ PrimarySuffix - │ │ └─ Arguments - │ │ └─ ArgumentList - │ │ └─ Expression - │ │ └─ PrimaryExpression - │ │ └─ PrimaryPrefix - │ │ └─ Literal - │ ├─ PrimarySuffix - │ └─ PrimarySuffix - │ └─ Arguments - │ └─ ArgumentList - │ └─ Expression - │ └─ PrimaryExpression - │ └─ PrimaryPrefix - │ └─ Name - └─ BlockStatement - └─ Statement - └─ ReturnStatement - └─ Expression - └─ PrimaryExpression - └─ PrimaryPrefix - └─ Name diff --git a/pmd-scala/src/test/kotlin/net/sourceforge/pmd/lang/scala/ast/ScalaParserTests.kt b/pmd-scala/src/test/kotlin/net/sourceforge/pmd/lang/scala/ast/ScalaParserTests.kt new file mode 100644 index 0000000000..b156424fa7 --- /dev/null +++ b/pmd-scala/src/test/kotlin/net/sourceforge/pmd/lang/scala/ast/ScalaParserTests.kt @@ -0,0 +1,23 @@ +/* + * BSD-style license; for more info see http://pmd.sourceforge.net/license.html + */ + +package net.sourceforge.pmd.lang.scala.ast + +import net.sourceforge.pmd.lang.ast.test.BaseParsingHelper +import net.sourceforge.pmd.lang.ast.test.BaseTreeDumpTest +import net.sourceforge.pmd.lang.ast.test.SimpleNodePrinter +import org.junit.Test + +class ScalaParserTests : BaseTreeDumpTest(SimpleNodePrinter, ".scala") { + + override val parser: BaseParsingHelper<*, *> + get() = ScalaParsingHelper.DEFAULT.withResourceContext(javaClass, "testdata") + + @Test + fun testSomeScalaFeatures() = doTest("List") + + @Test + fun testPackageObject() = doTest("package") + +} diff --git a/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.scala b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.scala new file mode 100644 index 0000000000..0c5ca22710 --- /dev/null +++ b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.scala @@ -0,0 +1,324 @@ +/* + * BSD-style license; for more info see http://pmd.sourceforge.net/license.html + */ + +package scala +package collection +package immutable + +import scala.annotation.unchecked.uncheckedVariance +import scala.annotation.tailrec +import mutable.{Builder, ListBuffer} +import scala.collection.generic.DefaultSerializable +import scala.runtime.Statics.releaseFence + +/** A class for immutable linked lists representing ordered collections + * of elements of type `A`. + * + */ +@SerialVersionUID(3L) +sealed abstract class List[+A] + extends AbstractSeq[A] + with LinearSeq[A] + with LinearSeqOps[A, List, List[A]] + with StrictOptimizedLinearSeqOps[A, List, List[A]] + with StrictOptimizedSeqOps[A, List, List[A]] + with IterableFactoryDefaults[A, List] + with DefaultSerializable { + + override def iterableFactory: SeqFactory[List] = List + + override def take(n: Int): List[A] = if (isEmpty || n <= 0) Nil else { + val h = new ::(head, Nil) + var t = h + var rest = tail + var i = 1 + while ( { + if (rest.isEmpty) return this; i < n + }) { + i += 1 + val nx = new ::(rest.head, Nil) + t.next = nx + t = nx + rest = rest.tail + } + releaseFence() + h + } + + /** + * @example {{{ + * // Given a list + * val letters = List('a','b','c','d','e') + * + * // `slice` returns all elements beginning at index `from` and afterwards, + * // up until index `until` (excluding index `until`.) + * letters.slice(1,3) // Returns List('b','c') + * }}} + */ + override def slice(from: Int, until: Int): List[A] = { + val lo = scala.math.max(from, 0) + if (until <= lo || isEmpty) Nil + else this drop lo take (until - lo) + } + + override def takeRight(n: Int): List[A] = { + @tailrec + def loop(lead: List[A], lag: List[A]): List[A] = lead match { + case Nil => lag + case _ :: tail => loop(tail, lag.tail) + } + loop(drop(n), this) + } + + // dropRight is inherited from LinearSeq + + override def splitAt(n: Int): (List[A], List[A]) = { + val b = new ListBuffer[A] + var i = 0 + var these = this + while (!these.isEmpty && i < n) { + i += 1 + b += these.head + these = these.tail + } + (b.toList, these) + } + + override def updated[B >: A](index: Int, elem: B): List[B] = { + var i = 0 + var current = this + val prefix = ListBuffer.empty[B] + while (i < index && current.nonEmpty) { + i += 1 + prefix += current.head + current = current.tail + } + if (i == index && current.nonEmpty) { + prefix.prependToList(elem :: current.tail) + } else { + throw new IndexOutOfBoundsException(s"$index is out of bounds (min 0, max ${leng t h-1})") + } + } + + final override def map[B](f: A => B): List[B] = { + if (this eq Nil) Nil else { + val h = new ::[B](f(head), Nil) + var t: ::[B] = h + var rest = tail + while (rest ne Nil) { + val nx = new ::(f(rest.head), Nil) + t.next = nx + t = nx + rest = rest.tail + } + releaseFence() + h + } + } + + final override def collect[B](pf: PartialFunction[A, B]): List[B] = { + if (this eq Nil) Nil else { + var rest = this + var h: ::[B] = null + var x: Any = null + // Special case for first element + while (h eq null) { + x = pf.applyOrElse(rest.head, List.partialNotApplied) + if (x.asInstanceOf[AnyRef] ne List.partialNotApplied) h = new ::(x.asInstanceOf[B], Nil) + rest = rest.tail + if (rest eq Nil) return if (h eq null) Nil else h + } + var t = h + // Remaining elements + while (rest ne Nil) { + x = pf.applyOrElse(rest.head, List.partialNotApplied) + if (x.asInstanceOf[AnyRef] ne List.partialNotApplied) { + val nx = new ::(x.asInstanceOf[B], Nil) + t.next = nx + t = nx + } + rest = rest.tail + } + releaseFence() + h + } + } + + final override def flatMap[B](f: A => IterableOnce[B]): List[B] = { + var rest = this + var h: ::[B] = null + var t: ::[B] = null + while (rest ne Nil) { + val it = f(rest.head).iterator + while (it.hasNext) { + val nx = new ::(it.next(), Nil) + if (t eq null) { + h = nx + } else { + t.next = nx + } + t = nx + } + rest = rest.tail + } + if (h eq null) Nil else {releaseFence(); h} + } + + @inline final override def takeWhile(p: A => Boolean): List[A] = { + val b = new ListBuffer[A] + var these = this + while (!these.isEmpty && p(these.head)) { + b += these.head + these = these.tail + } + b.toList + } + + @inline final override def span(p: A => Boolean): (List[A], List[A]) = { + val b = new ListBuffer[A] + var these = this + while (!these.isEmpty && p(these.head)) { + b += these.head + these = these.tail + } + (b.toList, these) + } + + // Overridden with an implementation identical to the inherited one (at this time) + // solely so it can be finalized and thus inlinable. + @inline final override def foreach[U](f: A => U): Unit = { + var these = this + while (!these.isEmpty) { + f(these.head) + these = these.tail + } + } + + final override def reverse: List[A] = { + var result: List[A] = Nil + var these = this + while (!these.isEmpty) { + result = these.head :: result + these = these.tail + } + result + } + + final override def foldRight[B](z: B)(op: (A, B) => B): B = { + var acc = z + var these: List[A] = reverse + while (!these.isEmpty) { + acc = op(these.head, acc) + these = these.tail + } + acc + } + + // Copy/Paste overrides to avoid interface calls inside loops. + + override final def length: Int = { + var these = this + var len = 0 + while (!these.isEmpty) { + len += 1 + these = these.tail + } + len + } + + override final def lengthCompare(len: Int): Int = { + @tailrec def loop(i: Int, xs: List[A]): Int = { + if (i == len) + if (xs.isEmpty) 0 else 1 + else if (xs.isEmpty) + -1 + else + loop(i + 1, xs.tail) + } + if (len < 0) 1 + else loop(0, coll) + } + + override final def forall(p: A => Boolean): Boolean = { + var these: List[A] = this + while (!these.isEmpty) { + if (!p(these.head)) return false + these = these.tail + } + true + } + + override final def exists(p: A => Boolean): Boolean = { + var these: List[A] = this + while (!these.isEmpty) { + if (p(these.head)) return true + these = these.tail + } + false + } + + override final def contains[A1 >: A](elem: A1): Boolean = { + var these: List[A] = this + while (!these.isEmpty) { + if (these.head == elem) return true + these = these.tail + } + false + } + + override final def find(p: A => Boolean): Option[A] = { + var these: List[A] = this + while (!these.isEmpty) { + if (p(these.head)) return Some(these.head) + these = these.tail + } + None + } +} +// Internal code that mutates `next` _must_ call `Statics.releaseFence()` if either immediately, or +// before a newly-allocated, thread-local :: instance is aliased (e.g. in ListBuffer.toList) +final case class :: [+A](override val head: A, private[scala] var next: List[A @uncheckedVariance]) // sound because `next` is used only locally + extends List[A] { + releaseFence() + override def headOption: Some[A] = Some(head) + override def tail: List[A] = next +} + +case object Nil extends List[Nothing] { + override def head: Nothing = throw new NoSuchElementException("head of empty list") + override def headOption: None.type = None + override def tail: Nothing = throw new UnsupportedOperationException("tail of empty list") + override def last: Nothing = throw new NoSuchElementException("last of empty list") + override def init: Nothing = throw new UnsupportedOperationException("init of empty list") + override def knownSize: Int = 0 + override def iterator: Iterator[Nothing] = Iterator.empty + override def unzip[A1, A2](implicit asPair: Nothing => (A1, A2)): (List[A1], List[A2]) = EmptyUnzip + + @transient + private[this] val EmptyUnzip = (Nil, Nil) +} + +/** + * $factoryInfo + * @define coll list + * @define Coll `List` + */ +@SerialVersionUID(3L) +object List extends StrictOptimizedSeqFactory[List] { + private val TupleOfNil = (Nil, Nil) + + def from[B](coll: collection.IterableOnce[B]): List[B] = coll match { + case coll: List[B] => coll + case _ if coll.knownSize == 0 => empty[B] + case b: ListBuffer[B] => b.toList + case _ => ListBuffer.from(coll).toList + } + + def newBuilder[A]: Builder[A, List[A]] = new ListBuffer() + + def empty[A]: List[A] = Nil + + @transient + private[collection] val partialNotApplied = new Function1[Any, Any] { def apply(x: Any): Any = this } +} diff --git a/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.txt b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.txt new file mode 100644 index 0000000000..e8aadb608f --- /dev/null +++ b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/List.txt @@ -0,0 +1,1634 @@ +└─ Source + └─ Pkg + ├─ TermName + └─ Pkg + ├─ TermName + └─ Pkg + ├─ TermName + ├─ Import + │ └─ Importer + │ ├─ TermSelect + │ │ ├─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ └─ ImporteeName + │ └─ NameIndeterminate + ├─ Import + │ └─ Importer + │ ├─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ └─ ImporteeName + │ └─ NameIndeterminate + ├─ Import + │ └─ Importer + │ ├─ TermName + │ ├─ ImporteeName + │ │ └─ NameIndeterminate + │ └─ ImporteeName + │ └─ NameIndeterminate + ├─ Import + │ └─ Importer + │ ├─ TermSelect + │ │ ├─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ └─ ImporteeName + │ └─ NameIndeterminate + ├─ Import + │ └─ Importer + │ ├─ TermSelect + │ │ ├─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ └─ ImporteeName + │ └─ NameIndeterminate + ├─ DefnClass + │ ├─ ModAnnot + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ └─ LitLong + │ ├─ ModSealed + │ ├─ ModAbstract + │ ├─ TypeName + │ ├─ TypeParam + │ │ ├─ ModCovariant + │ │ ├─ TypeName + │ │ └─ TypeBounds + │ ├─ CtorPrimary + │ │ └─ NameAnonymous + │ └─ Template + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Init + │ │ ├─ TypeName + │ │ └─ NameAnonymous + │ ├─ Self + │ │ └─ NameAnonymous + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermIf + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermName + │ │ │ ├─ TermName + │ │ │ └─ TermApplyInfix + │ │ │ ├─ TermName + │ │ │ ├─ TermName + │ │ │ └─ LitInt + │ │ ├─ TermName + │ │ └─ TermBlock + │ │ ├─ DefnVal + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermNew + │ │ │ └─ Init + │ │ │ ├─ TypeName + │ │ │ ├─ NameAnonymous + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermName + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermName + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ LitInt + │ │ ├─ TermWhile + │ │ │ ├─ TermBlock + │ │ │ │ ├─ TermIf + │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ ├─ TermReturn + │ │ │ │ │ │ └─ TermThis + │ │ │ │ │ │ └─ NameAnonymous + │ │ │ │ │ └─ LitUnit + │ │ │ │ └─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ LitInt + │ │ │ ├─ DefnVal + │ │ │ │ ├─ PatVar + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermNew + │ │ │ │ └─ Init + │ │ │ │ ├─ TypeName + │ │ │ │ ├─ NameAnonymous + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermApply + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVal + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermApply + │ │ │ ├─ TermSelect + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermName + │ │ │ └─ LitInt + │ │ └─ TermIf + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermName + │ │ └─ TermApplyInfix + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermThis + │ │ │ │ └─ NameAnonymous + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermName + │ │ └─ TermApplyInfix + │ │ ├─ TermName + │ │ ├─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnDef + │ │ │ ├─ ModAnnot + │ │ │ │ └─ Init + │ │ │ │ ├─ TypeName + │ │ │ │ └─ NameAnonymous + │ │ │ ├─ TermName + │ │ │ ├─ TermParam + │ │ │ │ ├─ TermName + │ │ │ │ └─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ ├─ TermParam + │ │ │ │ ├─ TermName + │ │ │ │ └─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TermMatch + │ │ │ ├─ TermName + │ │ │ ├─ Case + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ Case + │ │ │ ├─ PatExtractInfix + │ │ │ │ ├─ PatWildcard + │ │ │ │ ├─ TermName + │ │ │ │ └─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermApply + │ │ │ ├─ TermName + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermApply + │ │ ├─ TermName + │ │ ├─ TermApply + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermThis + │ │ └─ NameAnonymous + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TypeTuple + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVal + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermNew + │ │ │ └─ Init + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ NameAnonymous + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ LitInt + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermApplyUnary + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ LitInt + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermTuple + │ │ ├─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ │ └─ TypeName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ LitInt + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ DefnVal + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermApplyType + │ │ │ ├─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TypeName + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermApplyInfix + │ │ │ │ │ ├─ TermName + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ LitInt + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermIf + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermBlock + │ │ │ └─ TermApply + │ │ │ ├─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermApplyInfix + │ │ │ ├─ TermName + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermBlock + │ │ └─ TermThrow + │ │ └─ TermNew + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ └─ TermInterpolate + │ │ ├─ TermName + │ │ ├─ LitString + │ │ ├─ LitString + │ │ ├─ LitString + │ │ ├─ TermName + │ │ └─ TermApplyInfix + │ │ ├─ TermName + │ │ ├─ TermName + │ │ └─ TermApplyInfix + │ │ ├─ TermName + │ │ ├─ TermName + │ │ └─ LitInt + │ ├─ DefnDef + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ └─ TermIf + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermThis + │ │ │ │ └─ NameAnonymous + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermName + │ │ └─ TermBlock + │ │ ├─ DefnVal + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermNew + │ │ │ └─ Init + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ ├─ NameAnonymous + │ │ │ ├─ TermApply + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermName + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TermName + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermName + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ DefnVal + │ │ │ │ ├─ PatVar + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermNew + │ │ │ │ └─ Init + │ │ │ │ ├─ TypeName + │ │ │ │ ├─ NameAnonymous + │ │ │ │ ├─ TermApply + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermApply + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ └─ TermIf + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermThis + │ │ │ │ └─ NameAnonymous + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ LitNull + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeName + │ │ │ └─ LitNull + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ LitNull + │ │ │ └─ TermBlock + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermApply + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermIf + │ │ │ │ ├─ TermApplyInfix + │ │ │ │ │ ├─ TermApplyType + │ │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ │ └─ TermName + │ │ │ │ │ │ └─ TypeName + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermAssign + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermNew + │ │ │ │ │ └─ Init + │ │ │ │ │ ├─ TypeName + │ │ │ │ │ ├─ NameAnonymous + │ │ │ │ │ ├─ TermApplyType + │ │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ │ └─ TermName + │ │ │ │ │ │ └─ TypeName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ LitUnit + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermIf + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermReturn + │ │ │ │ └─ TermIf + │ │ │ │ ├─ TermApplyInfix + │ │ │ │ │ ├─ TermName + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ LitNull + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ LitUnit + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermName + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermApply + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermIf + │ │ │ │ ├─ TermApplyInfix + │ │ │ │ │ ├─ TermApplyType + │ │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ │ └─ TermName + │ │ │ │ │ │ └─ TypeName + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermBlock + │ │ │ │ │ ├─ DefnVal + │ │ │ │ │ │ ├─ PatVar + │ │ │ │ │ │ │ └─ TermName + │ │ │ │ │ │ └─ TermNew + │ │ │ │ │ │ └─ Init + │ │ │ │ │ │ ├─ TypeName + │ │ │ │ │ │ ├─ NameAnonymous + │ │ │ │ │ │ ├─ TermApplyType + │ │ │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ │ │ └─ TermName + │ │ │ │ │ │ │ └─ TypeName + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ ├─ TermAssign + │ │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ │ └─ TermName + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ └─ TermAssign + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ LitUnit + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ ├─ TermApply + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ LitNull + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ LitNull + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ DefnVal + │ │ │ │ ├─ PatVar + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermApply + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermWhile + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermBlock + │ │ │ │ ├─ DefnVal + │ │ │ │ │ ├─ PatVar + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ └─ TermNew + │ │ │ │ │ └─ Init + │ │ │ │ │ ├─ TypeName + │ │ │ │ │ ├─ NameAnonymous + │ │ │ │ │ ├─ TermApply + │ │ │ │ │ │ └─ TermSelect + │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermIf + │ │ │ │ │ ├─ TermApplyInfix + │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ └─ LitNull + │ │ │ │ │ ├─ TermBlock + │ │ │ │ │ │ └─ TermAssign + │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ └─ TermBlock + │ │ │ │ │ └─ TermAssign + │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermIf + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermName + │ │ │ ├─ TermName + │ │ │ └─ LitNull + │ │ ├─ TermName + │ │ └─ TermBlock + │ │ ├─ TermApply + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModAnnot + │ │ │ └─ Init + │ │ │ ├─ TypeName + │ │ │ └─ NameAnonymous + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVal + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermNew + │ │ │ └─ Init + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ NameAnonymous + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermApplyUnary + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermApply + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModAnnot + │ │ │ └─ Init + │ │ │ ├─ TypeName + │ │ │ └─ NameAnonymous + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeTuple + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVal + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermNew + │ │ │ └─ Init + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ NameAnonymous + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermApplyUnary + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermApply + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermTuple + │ │ ├─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModAnnot + │ │ │ └─ Init + │ │ │ ├─ TypeName + │ │ │ └─ NameAnonymous + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ └─ TermWhile + │ │ ├─ TermApplyUnary + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermBlock + │ │ ├─ TermApply + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermAssign + │ │ ├─ TermName + │ │ └─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TermName + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyUnary + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermApplyInfix + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModFinal + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermName + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TermName + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyUnary + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermAssign + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermApply + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ ModFinal + │ │ ├─ TermName + │ │ ├─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ LitInt + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyUnary + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ LitInt + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ ModFinal + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnDef + │ │ │ ├─ ModAnnot + │ │ │ │ └─ Init + │ │ │ │ ├─ TypeName + │ │ │ │ └─ NameAnonymous + │ │ │ ├─ TermName + │ │ │ ├─ TermParam + │ │ │ │ ├─ TermName + │ │ │ │ └─ TypeName + │ │ │ ├─ TermParam + │ │ │ │ ├─ TermName + │ │ │ │ └─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ ├─ TypeName + │ │ │ └─ TermBlock + │ │ │ └─ TermIf + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermIf + │ │ │ │ ├─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ LitInt + │ │ │ │ └─ LitInt + │ │ │ └─ TermIf + │ │ │ ├─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ LitInt + │ │ │ └─ TermApply + │ │ │ ├─ TermName + │ │ │ ├─ TermApplyInfix + │ │ │ │ ├─ TermName + │ │ │ │ ├─ TermName + │ │ │ │ └─ LitInt + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermIf + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermName + │ │ │ ├─ TermName + │ │ │ └─ LitInt + │ │ ├─ LitInt + │ │ └─ TermApply + │ │ ├─ TermName + │ │ ├─ LitInt + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ ModFinal + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyUnary + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermIf + │ │ │ │ ├─ TermApplyUnary + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermApply + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermReturn + │ │ │ │ │ └─ LitBoolean + │ │ │ │ └─ LitUnit + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ LitBoolean + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ ModFinal + │ │ ├─ TermName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyUnary + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermIf + │ │ │ │ ├─ TermApply + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermSelect + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermReturn + │ │ │ │ │ └─ LitBoolean + │ │ │ │ └─ LitUnit + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ LitBoolean + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ ModFinal + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ │ └─ TypeName + │ │ ├─ TermParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ ├─ TypeName + │ │ └─ TermBlock + │ │ ├─ DefnVar + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TermThis + │ │ │ └─ NameAnonymous + │ │ ├─ TermWhile + │ │ │ ├─ TermApplyUnary + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ TermBlock + │ │ │ ├─ TermIf + │ │ │ │ ├─ TermApplyInfix + │ │ │ │ │ ├─ TermSelect + │ │ │ │ │ │ ├─ TermName + │ │ │ │ │ │ └─ TermName + │ │ │ │ │ ├─ TermName + │ │ │ │ │ └─ TermName + │ │ │ │ ├─ TermReturn + │ │ │ │ │ └─ LitBoolean + │ │ │ │ └─ LitUnit + │ │ │ └─ TermAssign + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ LitBoolean + │ └─ DefnDef + │ ├─ ModOverride + │ ├─ ModFinal + │ ├─ TermName + │ ├─ TermParam + │ │ ├─ TermName + │ │ └─ TypeFunction + │ │ ├─ TypeName + │ │ └─ TypeName + │ ├─ TypeApply + │ │ ├─ TypeName + │ │ └─ TypeName + │ └─ TermBlock + │ ├─ DefnVar + │ │ ├─ PatVar + │ │ │ └─ TermName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermThis + │ │ └─ NameAnonymous + │ ├─ TermWhile + │ │ ├─ TermApplyUnary + │ │ │ ├─ TermName + │ │ │ └─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermBlock + │ │ ├─ TermIf + │ │ │ ├─ TermApply + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermReturn + │ │ │ │ └─ TermApply + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ └─ LitUnit + │ │ └─ TermAssign + │ │ ├─ TermName + │ │ └─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ └─ TermName + ├─ DefnClass + │ ├─ ModFinal + │ ├─ ModCase + │ ├─ TypeName + │ ├─ TypeParam + │ │ ├─ ModCovariant + │ │ ├─ TypeName + │ │ └─ TypeBounds + │ ├─ CtorPrimary + │ │ ├─ NameAnonymous + │ │ ├─ TermParam + │ │ │ ├─ ModOverride + │ │ │ ├─ ModValParam + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ └─ TermParam + │ │ ├─ ModPrivate + │ │ │ └─ NameIndeterminate + │ │ ├─ ModVarParam + │ │ ├─ TermName + │ │ └─ TypeApply + │ │ ├─ TypeName + │ │ └─ TypeAnnotate + │ │ ├─ TypeName + │ │ └─ ModAnnot + │ │ └─ Init + │ │ ├─ TypeName + │ │ └─ NameAnonymous + │ └─ Template + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Self + │ │ └─ NameAnonymous + │ ├─ TermApply + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermApply + │ │ ├─ TermName + │ │ └─ TermName + │ └─ DefnDef + │ ├─ ModOverride + │ ├─ TermName + │ ├─ TypeApply + │ │ ├─ TypeName + │ │ └─ TypeName + │ └─ TermName + ├─ DefnObject + │ ├─ ModCase + │ ├─ TermName + │ └─ Template + │ ├─ Init + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ NameAnonymous + │ ├─ Self + │ │ └─ NameAnonymous + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeName + │ │ └─ TermThrow + │ │ └─ TermNew + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ └─ LitString + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeSingleton + │ │ │ └─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeName + │ │ └─ TermThrow + │ │ └─ TermNew + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ └─ LitString + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeName + │ │ └─ TermThrow + │ │ └─ TermNew + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ └─ LitString + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeName + │ │ └─ TermThrow + │ │ └─ TermNew + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ └─ LitString + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeName + │ │ └─ LitInt + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ ├─ DefnDef + │ │ ├─ ModOverride + │ │ ├─ TermName + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ ├─ TypeParam + │ │ │ ├─ TypeName + │ │ │ └─ TypeBounds + │ │ ├─ TermParam + │ │ │ ├─ ModImplicit + │ │ │ ├─ TermName + │ │ │ └─ TypeFunction + │ │ │ ├─ TypeName + │ │ │ └─ TypeTuple + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ ├─ TypeTuple + │ │ │ ├─ TypeApply + │ │ │ │ ├─ TypeName + │ │ │ │ └─ TypeName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermName + │ └─ DefnVal + │ ├─ ModAnnot + │ │ └─ Init + │ │ ├─ TypeName + │ │ └─ NameAnonymous + │ ├─ ModPrivate + │ │ └─ TermThis + │ │ └─ NameAnonymous + │ ├─ PatVar + │ │ └─ TermName + │ └─ TermTuple + │ ├─ TermName + │ └─ TermName + └─ DefnObject + ├─ ModAnnot + │ └─ Init + │ ├─ TypeName + │ ├─ NameAnonymous + │ └─ LitLong + ├─ TermName + └─ Template + ├─ Init + │ ├─ TypeApply + │ │ ├─ TypeName + │ │ └─ TypeName + │ └─ NameAnonymous + ├─ Self + │ └─ NameAnonymous + ├─ DefnVal + │ ├─ ModPrivate + │ │ └─ NameAnonymous + │ ├─ PatVar + │ │ └─ TermName + │ └─ TermTuple + │ ├─ TermName + │ └─ TermName + ├─ DefnDef + │ ├─ TermName + │ ├─ TypeParam + │ │ ├─ TypeName + │ │ └─ TypeBounds + │ ├─ TermParam + │ │ ├─ TermName + │ │ └─ TypeApply + │ │ ├─ TypeSelect + │ │ │ ├─ TermName + │ │ │ └─ TypeName + │ │ └─ TypeName + │ ├─ TypeApply + │ │ ├─ TypeName + │ │ └─ TypeName + │ └─ TermMatch + │ ├─ TermName + │ ├─ Case + │ │ ├─ PatTyped + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermName + │ ├─ Case + │ │ ├─ PatWildcard + │ │ ├─ TermApplyInfix + │ │ │ ├─ TermSelect + │ │ │ │ ├─ TermName + │ │ │ │ └─ TermName + │ │ │ ├─ TermName + │ │ │ └─ LitInt + │ │ └─ TermApplyType + │ │ ├─ TermName + │ │ └─ TypeName + │ ├─ Case + │ │ ├─ PatTyped + │ │ │ ├─ PatVar + │ │ │ │ └─ TermName + │ │ │ └─ TypeApply + │ │ │ ├─ TypeName + │ │ │ └─ TypeName + │ │ └─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ └─ Case + │ ├─ PatWildcard + │ └─ TermSelect + │ ├─ TermApply + │ │ ├─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ └─ TermName + ├─ DefnDef + │ ├─ TermName + │ ├─ TypeParam + │ │ ├─ TypeName + │ │ └─ TypeBounds + │ ├─ TypeApply + │ │ ├─ TypeName + │ │ ├─ TypeName + │ │ └─ TypeApply + │ │ ├─ TypeName + │ │ └─ TypeName + │ └─ TermNew + │ └─ Init + │ ├─ TypeName + │ └─ NameAnonymous + ├─ DefnDef + │ ├─ TermName + │ ├─ TypeParam + │ │ ├─ TypeName + │ │ └─ TypeBounds + │ ├─ TypeApply + │ │ ├─ TypeName + │ │ └─ TypeName + │ └─ TermName + └─ DefnVal + ├─ ModAnnot + │ └─ Init + │ ├─ TypeName + │ └─ NameAnonymous + ├─ ModPrivate + │ └─ NameIndeterminate + ├─ PatVar + │ └─ TermName + └─ TermNewAnonymous + └─ Template + ├─ Init + │ ├─ TypeApply + │ │ ├─ TypeName + │ │ ├─ TypeName + │ │ └─ TypeName + │ └─ NameAnonymous + ├─ Self + │ └─ NameAnonymous + └─ DefnDef + ├─ TermName + ├─ TermParam + │ ├─ TermName + │ └─ TypeName + ├─ TypeName + └─ TermThis + └─ NameAnonymous diff --git a/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.scala b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.scala new file mode 100644 index 0000000000..4acf9bf2b7 --- /dev/null +++ b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.scala @@ -0,0 +1,22 @@ + +/* + * BSD-style license; for more info see http://pmd.sourceforge.net/license.html + */ + +package scala.collection + + +package object immutable { + type StringOps = scala.collection.StringOps + val StringOps = scala.collection.StringOps + type StringView = scala.collection.StringView + val StringView = scala.collection.StringView + + @deprecated("Use Iterable instead of Traversable", "2.13.0") + type Traversable[+X] = Iterable[X] + @deprecated("Use Iterable instead of Traversable", "2.13.0") + val Traversable = Iterable + + @deprecated("Use Map instead of DefaultMap", "2.13.0") + type DefaultMap[K, +V] = scala.collection.immutable.Map[K, V] +} \ No newline at end of file diff --git a/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.txt b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.txt new file mode 100644 index 0000000000..0f6823b890 --- /dev/null +++ b/pmd-scala/src/test/resources/net/sourceforge/pmd/lang/scala/ast/testdata/package.txt @@ -0,0 +1,90 @@ +└─ Source + └─ Pkg + ├─ TermSelect + │ ├─ TermName + │ └─ TermName + └─ PkgObject + ├─ TermName + └─ Template + ├─ Self + │ └─ NameAnonymous + ├─ DefnType + │ ├─ TypeName + │ └─ TypeSelect + │ ├─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ └─ TypeName + ├─ DefnVal + │ ├─ PatVar + │ │ └─ TermName + │ └─ TermSelect + │ ├─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ └─ TermName + ├─ DefnType + │ ├─ TypeName + │ └─ TypeSelect + │ ├─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ └─ TypeName + ├─ DefnVal + │ ├─ PatVar + │ │ └─ TermName + │ └─ TermSelect + │ ├─ TermSelect + │ │ ├─ TermName + │ │ └─ TermName + │ └─ TermName + ├─ DefnType + │ ├─ ModAnnot + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ ├─ LitString + │ │ └─ LitString + │ ├─ TypeName + │ ├─ TypeParam + │ │ ├─ ModCovariant + │ │ ├─ TypeName + │ │ └─ TypeBounds + │ └─ TypeApply + │ ├─ TypeName + │ └─ TypeName + ├─ DefnVal + │ ├─ ModAnnot + │ │ └─ Init + │ │ ├─ TypeName + │ │ ├─ NameAnonymous + │ │ ├─ LitString + │ │ └─ LitString + │ ├─ PatVar + │ │ └─ TermName + │ └─ TermName + └─ DefnType + ├─ ModAnnot + │ └─ Init + │ ├─ TypeName + │ ├─ NameAnonymous + │ ├─ LitString + │ └─ LitString + ├─ TypeName + ├─ TypeParam + │ ├─ TypeName + │ └─ TypeBounds + ├─ TypeParam + │ ├─ ModCovariant + │ ├─ TypeName + │ └─ TypeBounds + └─ TypeApply + ├─ TypeSelect + │ ├─ TermSelect + │ │ ├─ TermSelect + │ │ │ ├─ TermName + │ │ │ └─ TermName + │ │ └─ TermName + │ └─ TypeName + ├─ TypeName + └─ TypeName