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 c16ed30 commit fc279f0Copy full SHA for fc279f0
compiler/src/dotty/tools/dotc/core/Types.scala
@@ -134,7 +134,7 @@ object Types {
134
}
135
136
/** Is this type different from NoType? */
137
- def exists: Boolean = true
+ final def exists: Boolean = this.ne(NoType)
138
139
/** This type, if it exists, otherwise `that` type */
140
def orElse(that: => Type) = if (exists) this else that
@@ -3712,7 +3712,6 @@ object Types {
3712
3713
/** Sentinel for "missing type" */
3714
@sharable case object NoType extends CachedGroundType {
3715
- override def exists = false
3716
override def computeHash(bs: Binders) = hashSeed
3717
3718
0 commit comments