aboutsummaryrefslogtreecommitdiff
path: root/sbt-bridge/src/sbt-test/source-dependencies/fbounded-existentials/fbounds.scala
blob: 60fe4087997ddefa5126e2db61f5bf5eeb3dd8d6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
class Dep {
  // The API representation for `bla`'s result type contains a cycle
  // (an existential's type variable's bound is the existential type itself)
  // This results in a stack overflow while showing the API diff.
  // Note that the actual result type in the compiler is not cyclic
  // (the f-bounded existential for Comparable is truncated)
  def bla(c: Boolean) = if (c) new Value else "bla"
}

class Value extends java.lang.Comparable[Value] { def compareTo(that: Value): Int = 1 }