Skip to content

Commit af0150a

Browse files
committed
Fix stdlib CB: don't check language patches
The owners are different for the patches, and they are always safe.
1 parent ad73bf2 commit af0150a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

compiler/src/dotty/tools/dotc/transform/init/Checker.scala

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import ast.tpd
99
import dotty.tools.dotc.core._
1010
import Contexts._
1111
import Types._
12+
import Symbols._
1213

1314
import dotty.tools.dotc.transform._
1415
import MegaPhase._
@@ -45,7 +46,7 @@ class Checker extends MiniPhase {
4546
}
4647

4748
// A concrete class may not be instantiated if the self type is not satisfied
48-
if (instantiable) {
49+
if (instantiable && cls.enclosingPackageClass != defn.StdLibPatchesPackage.moduleClass) {
4950
implicit val state: Checking.State = Checking.State(
5051
checked = Set.empty,
5152
path = Vector.empty,

0 commit comments

Comments
 (0)