File tree Expand file tree Collapse file tree 4 files changed +25
-5
lines changed
compiler/src/dotty/tools/dotc Expand file tree Collapse file tree 4 files changed +25
-5
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,8 @@ object ScalaSettings:
37
37
ScalaRelease .values.toList.map(_.show)
38
38
39
39
def supportedSourceVersions : List [String ] =
40
- SourceVersion .values.toList.map(_.toString)
40
+ SourceVersion .values.diff(SourceVersion .illegalInSettings)
41
+ .map(_.toString).toList
41
42
42
43
def defaultClasspath : String = sys.env.getOrElse(" CLASSPATH" , " ." )
43
44
Original file line number Diff line number Diff line change @@ -630,8 +630,13 @@ class TreePickler(pickler: TastyPickler) {
630
630
case tree : TypeTree =>
631
631
pickleType(tree.tpe)
632
632
case SingletonTypeTree (ref) =>
633
- writeByte(SINGLETONtpt )
634
- pickleTree(ref)
633
+ val tp = ref.tpe
634
+ val tp1 = tp.deskolemized
635
+ if tp1 ne tp then
636
+ pickleType(tp1)
637
+ else
638
+ writeByte(SINGLETONtpt )
639
+ pickleTree(ref)
635
640
case RefinedTypeTree (parent, refinements) =>
636
641
if (refinements.isEmpty) pickleTree(parent)
637
642
else {
Original file line number Diff line number Diff line change @@ -24,8 +24,8 @@ object Test {
24
24
}
25
25
26
26
trait A
27
- case class B () extends A // error: Line is indented too far to the right
28
- case object C extends A // error: Line is indented too far to the right
27
+ case class B () extends A
28
+ case object C extends A
29
29
30
30
if (true ) // OK
31
31
println(" hi" )
Original file line number Diff line number Diff line change
1
+ class R [T ] extends annotation.StaticAnnotation
2
+
3
+ class A [T ]:
4
+ val next : A [T ] = null
5
+ val self : this .type = this
6
+ val selfnext : this .next.type = this .next
7
+ def f : (A [T ] @ R [this .type ], A [T ] @ R [this .next.type ]) = ???
8
+ def g : (A [T ] @ R [self.type ], A [T ] @ R [selfnext.type ]) = ???
9
+
10
+ class Test :
11
+ def test =
12
+ val (a, b) = A [String ]().f
13
+ val (a2, b2) = A [String ]().g
14
+
You can’t perform that action at this time.
0 commit comments