Skip to content

Commit c854cc7

Browse files
oderskygzm0
authored andcommitted
More tests
1 parent 474b35f commit c854cc7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+25
-20
lines changed

tests/untried/pos/t1071.scala renamed to tests/pending/pos/t1071.scala

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,5 @@ object Test {
1515
c.a // error
1616
}
1717

18+
// to fix this we'd need to check accessibility in the isMatchedBy of a SelectionProto,
19+
// so that we can insert an implicit if this does not work. Need to check performance impact of this.

tests/pending/pos/t1208.scala

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
object Test {
2+
object Foo
3+
val f: Option[Foo.type] = Some(Foo)
4+
}
5+
6+
// unsupported with current typing rules.
7+
// on the other hand, we need a way to refer to a module class.

tests/untried/pos/t1236.scala renamed to tests/pending/pos/t1236.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ trait Empty[E[_]] {
44

55
object T {
66
val ListEmpty = new Empty[List] {
7-
def e[A] = Nil
7+
def e[A]/*: List*/ = Nil // uncomment to get crash
88
}
99

1010
def foo[F[_]](q:(String,String)) = "hello"
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

tests/untried/pos/t1035.scala renamed to tests/pos/t1035.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
class A {
77
var name:String = _
88
def getName() = name
9-
def this(name:String, age:Int){this();this.name=name}
9+
def this(name:String, age:Int) = {this(); this.name = name}
1010

1111
}
1212

tests/pos/t1048.scala

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
trait T[U] {
2+
def x: T[_ <: U]
3+
}
4+
5+
object T {
6+
def unapply[U](t: T[U]): Option[T[_ <: U]] = Some(t.x)
7+
}
8+
9+
object Test {
10+
def f[W](t: T[W]) = t match {
11+
case T(T(_)) => ()
12+
}
13+
}
14+
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

tests/untried/pos/t1048.scala

Lines changed: 0 additions & 14 deletions
This file was deleted.

tests/untried/pos/t1208.scala

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)