File tree Expand file tree Collapse file tree 4 files changed +6
-3
lines changed
compiler/src/dotty/tools/dotc Expand file tree Collapse file tree 4 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -658,6 +658,9 @@ object SymDenotations {
658658 containsOpaques ||
659659 is(Module , butNot = Package ) && owner.seesOpaques
660660
661+ def isProvisional (using Context ): Boolean =
662+ flagsUNSAFE.is(Provisional ) // do not force the info to check the flag
663+
661664 /** Is this the denotation of a self symbol of some class?
662665 * This is the case if one of two conditions holds:
663666 * 1. It is the symbol referred to in the selfInfo part of the ClassInfo
Original file line number Diff line number Diff line change @@ -285,7 +285,7 @@ class TypeApplications(val self: Type) extends AnyVal {
285285 /** Dealias type if it can be done without forcing the TypeRef's info */
286286 def safeDealias (using Context ): Type = self match {
287287 case self : TypeRef
288- if self.denot.exists && self.symbol.isAliasType && ! self.symbol.flagsUNSAFE.is( Provisional ) =>
288+ if self.denot.exists && self.symbol.isAliasType && ! self.symbol.isProvisional =>
289289 self.superType.stripTypeVar.safeDealias
290290 case _ =>
291291 self
Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ object Types {
118118 case t : TypeRef =>
119119 ! t.currentSymbol.isStatic && {
120120 (t : Type ).mightBeProvisional = false // break cycles
121- t.symbol.flagsUNSAFE.is( Provisional )
121+ t.symbol.isProvisional
122122 || test(t.prefix, theAcc)
123123 || t.denot.infoOrCompleter.match
124124 case info : LazyType => true
Original file line number Diff line number Diff line change @@ -2030,7 +2030,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
20302030 if tycon == defn.andType || tycon == defn.orType then
20312031 checkedArgs = checkedArgs.mapconserve(arg =>
20322032 checkSimpleKinded(checkNoWildcard(arg)))
2033- else if tycon.flagsUNSAFE.is( Provisional ) then
2033+ else if tycon.isProvisional then
20342034 // A type with Provisional flag is either an alias or abstract type.
20352035 // If it is an alias type, it would mean the type is cyclic
20362036 // If it is an abstract type, it would mean the type is an irreducible
You can’t perform that action at this time.
0 commit comments