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.
1 parent 798e57e commit 0e5b505Copy full SHA for 0e5b505
compiler/src/dotty/tools/dotc/core/Types.scala
@@ -132,7 +132,7 @@ object Types {
132
}
133
134
/** Is this type different from NoType? */
135
- def exists: Boolean = true
+ final def exists: Boolean = this.ne(NoType)
136
137
/** This type, if it exists, otherwise `that` type */
138
def orElse(that: => Type) = if (exists) this else that
@@ -3764,7 +3764,6 @@ object Types {
3764
3765
/** Sentinel for "missing type" */
3766
@sharable case object NoType extends CachedGroundType {
3767
- override def exists = false
3768
override def computeHash(bs: Binders) = hashSeed
3769
3770
0 commit comments