summaryrefslogtreecommitdiff
path: root/test/files
diff options
context:
space:
mode:
Diffstat (limited to 'test/files')
-rw-r--r--test/files/neg/annot-nonconst.check4
-rw-r--r--test/files/neg/annot-nonconst.scala4
-rw-r--r--test/files/neg/reify_ann2b.check8
-rw-r--r--test/files/neg/reify_ann2b.scala2
-rw-r--r--test/files/pos/annot-inner.scala2
-rw-r--r--test/files/pos/annotDepMethType.scala2
-rw-r--r--test/files/pos/annotations.scala10
-rw-r--r--test/files/pos/attributes.scala14
-rw-r--r--test/files/pos/spec-annotations.scala2
-rw-r--r--test/files/pos/t1029/Test_1.scala2
-rw-r--r--test/files/pos/t1203.scala2
-rw-r--r--test/files/pos/t1942/A_1.scala2
-rw-r--r--test/files/pos/t2868/pick_1.scala2
-rw-r--r--test/files/pos/t3800.scala2
-rw-r--r--test/files/pos/t3951/Coll_1.scala2
-rw-r--r--test/files/run/bugs.scala3
-rw-r--r--test/files/run/macro-declared-in-annotation/Macros_2.scala2
-rw-r--r--test/files/run/reify_ann1a.scala2
-rw-r--r--test/files/run/reify_ann1b.scala2
-rw-r--r--test/files/run/reify_ann2a.scala2
-rw-r--r--test/files/run/reify_classfileann_a.scala2
-rw-r--r--test/files/run/reify_classfileann_b.scala2
-rw-r--r--test/files/run/t1500.scala2
-rw-r--r--test/files/run/t1501.scala2
-rw-r--r--test/files/run/t5224.scala2
-rw-r--r--test/files/run/t5419.scala2
-rw-r--r--test/files/run/t5423.scala2
27 files changed, 42 insertions, 43 deletions
diff --git a/test/files/neg/annot-nonconst.check b/test/files/neg/annot-nonconst.check
index e4166e08b6..b43e58a0ca 100644
--- a/test/files/neg/annot-nonconst.check
+++ b/test/files/neg/annot-nonconst.check
@@ -1,12 +1,12 @@
annot-nonconst.scala:1: warning: Implementation restriction: subclassing Classfile does not
make your annotation visible at runtime. If that is what
you want, you must write the annotation class in Java.
-class Length(value: Int) extends ClassfileAnnotation
+class Length(value: Int) extends annotation.ClassfileAnnotation
^
annot-nonconst.scala:2: warning: Implementation restriction: subclassing Classfile does not
make your annotation visible at runtime. If that is what
you want, you must write the annotation class in Java.
-class Ann2(value: String) extends ClassfileAnnotation
+class Ann2(value: String) extends annotation.ClassfileAnnotation
^
annot-nonconst.scala:6: error: annotation argument needs to be a constant; found: n
@Length(n) def foo = "foo"
diff --git a/test/files/neg/annot-nonconst.scala b/test/files/neg/annot-nonconst.scala
index 69bb60d34e..1b5856f8b2 100644
--- a/test/files/neg/annot-nonconst.scala
+++ b/test/files/neg/annot-nonconst.scala
@@ -1,5 +1,5 @@
-class Length(value: Int) extends ClassfileAnnotation
-class Ann2(value: String) extends ClassfileAnnotation
+class Length(value: Int) extends annotation.ClassfileAnnotation
+class Ann2(value: String) extends annotation.ClassfileAnnotation
object Test {
def n = 15
diff --git a/test/files/neg/reify_ann2b.check b/test/files/neg/reify_ann2b.check
index b9dd84c1ee..52bdbe5b7c 100644
--- a/test/files/neg/reify_ann2b.check
+++ b/test/files/neg/reify_ann2b.check
@@ -1,4 +1,4 @@
-reify_ann2b.scala:6: error: inner classes cannot be classfile annotations
- class ann(bar: String) extends ClassfileAnnotation
- ^
-one error found
+reify_ann2b.scala:6: error: inner classes cannot be classfile annotations
+ class ann(bar: String) extends annotation.ClassfileAnnotation
+ ^
+one error found
diff --git a/test/files/neg/reify_ann2b.scala b/test/files/neg/reify_ann2b.scala
index 6b6da8f790..397d00210d 100644
--- a/test/files/neg/reify_ann2b.scala
+++ b/test/files/neg/reify_ann2b.scala
@@ -3,7 +3,7 @@ import scala.reflect.mirror._
object Test extends App {
// test 1: reify
val tree = reify{
- class ann(bar: String) extends ClassfileAnnotation
+ class ann(bar: String) extends annotation.ClassfileAnnotation
@ann(bar="1a") @ann(bar="1b") class C[@ann(bar="2a") @ann(bar="2b") T](@ann(bar="3a") @ann(bar="3b") x: T @ann(bar="4a") @ann(bar="4b")) {
@ann(bar="5a") @ann(bar="5b") def f(x: Int @ann(bar="6a") @ann(bar="6b")) = {
diff --git a/test/files/pos/annot-inner.scala b/test/files/pos/annot-inner.scala
index f2ecb5ddb3..9f155a5a83 100644
--- a/test/files/pos/annot-inner.scala
+++ b/test/files/pos/annot-inner.scala
@@ -1,5 +1,5 @@
object test {
- class annot extends Annotation
+ class annot extends scala.annotation.Annotation
def foo {
@annot def bar(i: Int): Int = i
diff --git a/test/files/pos/annotDepMethType.scala b/test/files/pos/annotDepMethType.scala
index b5e7cb9e8b..079ca6224c 100644
--- a/test/files/pos/annotDepMethType.scala
+++ b/test/files/pos/annotDepMethType.scala
@@ -1,4 +1,4 @@
-case class pc(calls: Any*) extends TypeConstraint
+case class pc(calls: Any*) extends annotation.TypeConstraint
object Main {
class C0 { def baz: String = "" }
diff --git a/test/files/pos/annotations.scala b/test/files/pos/annotations.scala
index 4e5fddda39..706a715bad 100644
--- a/test/files/pos/annotations.scala
+++ b/test/files/pos/annotations.scala
@@ -1,5 +1,5 @@
-class ann(i: Int) extends Annotation
-class cfann(x: String) extends ClassfileAnnotation
+class ann(i: Int) extends scala.annotation.Annotation
+class cfann(x: String) extends annotation.ClassfileAnnotation
// annotations on abstract types
abstract class C1[@serializable @cloneable +T, U, V[_]]
@@ -91,9 +91,9 @@ trait BeanF {
}
-class Ann3(arr: Array[String]) extends ClassfileAnnotation
-class Ann4(i: Int) extends ClassfileAnnotation
-class Ann5(value: Class[_]) extends ClassfileAnnotation
+class Ann3(arr: Array[String]) extends annotation.ClassfileAnnotation
+class Ann4(i: Int) extends annotation.ClassfileAnnotation
+class Ann5(value: Class[_]) extends annotation.ClassfileAnnotation
object Test3 {
final val i = 1083
diff --git a/test/files/pos/attributes.scala b/test/files/pos/attributes.scala
index f3bbb4c42e..ec735d0aae 100644
--- a/test/files/pos/attributes.scala
+++ b/test/files/pos/attributes.scala
@@ -52,15 +52,15 @@ object O6 {
}
object myAttrs {
- class a1 extends scala.Annotation;
- class a2(x: Int) extends scala.Annotation;
- class a3(x: a1) extends scala.Annotation;
+ class a1 extends scala.annotation.Annotation;
+ class a2(x: Int) extends scala.annotation.Annotation;
+ class a3(x: a1) extends scala.annotation.Annotation;
}
-class a4(ns: Array[Int]) extends scala.Annotation;
+class a4(ns: Array[Int]) extends scala.annotation.Annotation;
object O7 {
- class a1 extends scala.Annotation;
- class a2(x: Int) extends scala.Annotation;
- class a3(x: a1) extends scala.Annotation;
+ class a1 extends scala.annotation.Annotation;
+ class a2(x: Int) extends scala.annotation.Annotation;
+ class a3(x: a1) extends scala.annotation.Annotation;
final val x = new a1;
@a1 class C1;
diff --git a/test/files/pos/spec-annotations.scala b/test/files/pos/spec-annotations.scala
index 35cab6de09..48281e5df5 100644
--- a/test/files/pos/spec-annotations.scala
+++ b/test/files/pos/spec-annotations.scala
@@ -1,4 +1,4 @@
-class ann(i: Int) extends Annotation
+class ann(i: Int) extends scala.annotation.Annotation
// annotations on abstract types
abstract class C1[@serializable @cloneable +T, U, V[_]]
diff --git a/test/files/pos/t1029/Test_1.scala b/test/files/pos/t1029/Test_1.scala
index e828087f2c..d268c71429 100644
--- a/test/files/pos/t1029/Test_1.scala
+++ b/test/files/pos/t1029/Test_1.scala
@@ -1,4 +1,4 @@
-class ann(a: Array[Int]) extends StaticAnnotation
+class ann(a: Array[Int]) extends annotation.StaticAnnotation
object Test1 {
// bug #1029
diff --git a/test/files/pos/t1203.scala b/test/files/pos/t1203.scala
index 4938621aa9..062ef93fc6 100644
--- a/test/files/pos/t1203.scala
+++ b/test/files/pos/t1203.scala
@@ -1,4 +1,4 @@
-case class ant(t: String) extends Annotation
+case class ant(t: String) extends scala.annotation.Annotation
object Test {
def main(args: Array[String]): Unit = {
val a: scala.xml.NodeSeq @ant("12") = Nil
diff --git a/test/files/pos/t1942/A_1.scala b/test/files/pos/t1942/A_1.scala
index 19a7575a0a..4915b54a64 100644
--- a/test/files/pos/t1942/A_1.scala
+++ b/test/files/pos/t1942/A_1.scala
@@ -3,7 +3,7 @@ class A {
def foo(x: String) = 1
}
-class ann(x: Int) extends StaticAnnotation
+class ann(x: Int) extends annotation.StaticAnnotation
class t {
val a = new A
diff --git a/test/files/pos/t2868/pick_1.scala b/test/files/pos/t2868/pick_1.scala
index e91728ec2f..a211687432 100644
--- a/test/files/pos/t2868/pick_1.scala
+++ b/test/files/pos/t2868/pick_1.scala
@@ -1,4 +1,4 @@
-class ann(s: String) extends StaticAnnotation
+class ann(s: String) extends annotation.StaticAnnotation
class pick {
final val s = "bang!"
@ann("bang!") def foo = 1
diff --git a/test/files/pos/t3800.scala b/test/files/pos/t3800.scala
index 796eb268c5..61dbeafff3 100644
--- a/test/files/pos/t3800.scala
+++ b/test/files/pos/t3800.scala
@@ -1,4 +1,4 @@
-class meh extends StaticAnnotation
+class meh extends annotation.StaticAnnotation
class ALike[C]
abstract class AFactory[CC[x] <: ALike[CC[x]]] {
diff --git a/test/files/pos/t3951/Coll_1.scala b/test/files/pos/t3951/Coll_1.scala
index c2cc39a1a9..556c848688 100644
--- a/test/files/pos/t3951/Coll_1.scala
+++ b/test/files/pos/t3951/Coll_1.scala
@@ -15,7 +15,7 @@ sealed trait DynamicDocument extends Document {
class Coll extends StaticDocument
// similiar issue with annotations
-class ann[T] extends StaticAnnotation
+class ann[T] extends annotation.StaticAnnotation
trait StatDoc extends Doc {
@ann[StatFB]
diff --git a/test/files/run/bugs.scala b/test/files/run/bugs.scala
index d5905af76c..ca598603bb 100644
--- a/test/files/run/bugs.scala
+++ b/test/files/run/bugs.scala
@@ -445,8 +445,7 @@ object Test {
test;
} catch {
case exception =>
- val curr: String = currentThread.toString();
- Console.print("Exception in thread \"" + curr + "\" " + exception);
+ Console.print("Exception in thread \"" + Thread.currentThread + "\" " + exception);
Console.println;
errors += 1
}
diff --git a/test/files/run/macro-declared-in-annotation/Macros_2.scala b/test/files/run/macro-declared-in-annotation/Macros_2.scala
index a565849aa9..40d71c62fb 100644
--- a/test/files/run/macro-declared-in-annotation/Macros_2.scala
+++ b/test/files/run/macro-declared-in-annotation/Macros_2.scala
@@ -1,4 +1,4 @@
-class foo(val bar: String) extends StaticAnnotation
+class foo(val bar: String) extends annotation.StaticAnnotation
object Api {
// foo in ann must have a different name
diff --git a/test/files/run/reify_ann1a.scala b/test/files/run/reify_ann1a.scala
index 1f5d1daccd..6c062ca2c2 100644
--- a/test/files/run/reify_ann1a.scala
+++ b/test/files/run/reify_ann1a.scala
@@ -1,6 +1,6 @@
import scala.reflect.mirror._
-class ann(bar: List[String]) extends StaticAnnotation
+class ann(bar: List[String]) extends annotation.StaticAnnotation
object Test extends App {
// test 1: reify
diff --git a/test/files/run/reify_ann1b.scala b/test/files/run/reify_ann1b.scala
index 13d861a15c..4faddef72c 100644
--- a/test/files/run/reify_ann1b.scala
+++ b/test/files/run/reify_ann1b.scala
@@ -1,6 +1,6 @@
import scala.reflect.mirror._
-class ann(bar: String) extends ClassfileAnnotation
+class ann(bar: String) extends annotation.ClassfileAnnotation
object Test extends App {
// test 1: reify
diff --git a/test/files/run/reify_ann2a.scala b/test/files/run/reify_ann2a.scala
index 370abadba0..a1723c221d 100644
--- a/test/files/run/reify_ann2a.scala
+++ b/test/files/run/reify_ann2a.scala
@@ -3,7 +3,7 @@ import scala.reflect.mirror._
object Test extends App {
// test 1: reify
val tree = reify{
- class ann(bar: List[String]) extends StaticAnnotation
+ class ann(bar: List[String]) extends annotation.StaticAnnotation
@ann(bar=List("1a")) @ann(bar=List("1b")) class C[@ann(bar=List("2a")) @ann(bar=List("2b")) T](@ann(bar=List("3a")) @ann(bar=List("3b")) x: T @ann(bar=List("4a")) @ann(bar=List("4b"))) {
@ann(bar=List("5a")) @ann(bar=List("5b")) def f(x: Int @ann(bar=List("6a")) @ann(bar=List("6b"))) = {
diff --git a/test/files/run/reify_classfileann_a.scala b/test/files/run/reify_classfileann_a.scala
index c3e7d8d2e9..9aec69b4a3 100644
--- a/test/files/run/reify_classfileann_a.scala
+++ b/test/files/run/reify_classfileann_a.scala
@@ -1,6 +1,6 @@
import scala.reflect.mirror._
-class ann(bar: String, quux: Array[String] = Array(), baz: ann = null) extends ClassfileAnnotation
+class ann(bar: String, quux: Array[String] = Array(), baz: ann = null) extends annotation.ClassfileAnnotation
object Test extends App {
// test 1: reify
diff --git a/test/files/run/reify_classfileann_b.scala b/test/files/run/reify_classfileann_b.scala
index 4e50494af3..a37f20e72e 100644
--- a/test/files/run/reify_classfileann_b.scala
+++ b/test/files/run/reify_classfileann_b.scala
@@ -1,6 +1,6 @@
import scala.reflect.mirror._
-class ann(bar: String, quux: Array[String] = Array(), baz: ann = null) extends ClassfileAnnotation
+class ann(bar: String, quux: Array[String] = Array(), baz: ann = null) extends annotation.ClassfileAnnotation
object Test extends App {
// test 1: reify
diff --git a/test/files/run/t1500.scala b/test/files/run/t1500.scala
index c312a9a883..586a2666ad 100644
--- a/test/files/run/t1500.scala
+++ b/test/files/run/t1500.scala
@@ -8,7 +8,7 @@ object Test {
val testCode = <code>
- class posingAs[A] extends TypeConstraint
+ class posingAs[A] extends annotation.TypeConstraint
def resolve[A,B](x: A @posingAs[B]): B = x.asInstanceOf[B]
diff --git a/test/files/run/t1501.scala b/test/files/run/t1501.scala
index 05e4da8c7a..dee6e0c68e 100644
--- a/test/files/run/t1501.scala
+++ b/test/files/run/t1501.scala
@@ -8,7 +8,7 @@ object Test {
val testCode = <code>
- class xyz[A] extends TypeConstraint
+ class xyz[A] extends annotation.TypeConstraint
def loopWhile[T](cond: =>Boolean)(body: =>(Unit @xyz[T])): Unit @ xyz[T] = {{
if (cond) {{
diff --git a/test/files/run/t5224.scala b/test/files/run/t5224.scala
index 93b244e03e..cf65f16457 100644
--- a/test/files/run/t5224.scala
+++ b/test/files/run/t5224.scala
@@ -1,6 +1,6 @@
import scala.reflect.mirror._
-class Foo(bar: String) extends ClassfileAnnotation
+class Foo(bar: String) extends annotation.ClassfileAnnotation
object Test extends App {
val tree = reify{@Foo(bar = "qwe") class C}.tree
diff --git a/test/files/run/t5419.scala b/test/files/run/t5419.scala
index d65d8f38c8..5f11f5056c 100644
--- a/test/files/run/t5419.scala
+++ b/test/files/run/t5419.scala
@@ -1,6 +1,6 @@
import scala.reflect.mirror._
-class Foo extends StaticAnnotation
+class Foo extends annotation.StaticAnnotation
object Test extends App {
val tree = reify{(5: @Foo).asInstanceOf[Int]}.tree
diff --git a/test/files/run/t5423.scala b/test/files/run/t5423.scala
index 645c8c7c1d..ed1faf0429 100644
--- a/test/files/run/t5423.scala
+++ b/test/files/run/t5423.scala
@@ -1,6 +1,6 @@
import scala.reflect.mirror._
-final class table extends StaticAnnotation
+final class table extends annotation.StaticAnnotation
@table class A
object Test extends App {