summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-04-28 11:52:10 -0700
committerPaul Phillips <paulp@improving.org>2012-04-28 13:48:22 -0700
commit14144be0bcd3f6823a9622c6f962aed295ef3392 (patch)
treee031f6fd8c87d7289e9841490c60888b14d558c8
parentd1460afa09989bcecb306b3cf78880cea39cbdc7 (diff)
downloadscala-14144be0bcd3f6823a9622c6f962aed295ef3392.tar.gz
scala-14144be0bcd3f6823a9622c6f962aed295ef3392.tar.bz2
scala-14144be0bcd3f6823a9622c6f962aed295ef3392.zip
Removed a few more @deprecated members.
The ones which remain I'm not removing on purpose, as I know from experience it's more trouble than it's yet worth.
-rw-r--r--src/compiler/scala/reflect/internal/TreeGen.scala15
-rw-r--r--src/compiler/scala/tools/nsc/javac/JavaParsers.scala13
-rw-r--r--src/library/scala/Predef.scala7
-rw-r--r--src/library/scala/collection/immutable/Range.scala3
-rw-r--r--src/library/scala/package.scala13
-rw-r--r--src/library/scala/reflect/makro/internal/macroImpl.scala2
-rw-r--r--src/library/scala/runtime/package.scala12
-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
34 files changed, 59 insertions, 91 deletions
diff --git a/src/compiler/scala/reflect/internal/TreeGen.scala b/src/compiler/scala/reflect/internal/TreeGen.scala
index f30ec67c7e..f2f9842595 100644
--- a/src/compiler/scala/reflect/internal/TreeGen.scala
+++ b/src/compiler/scala/reflect/internal/TreeGen.scala
@@ -7,13 +7,14 @@ abstract class TreeGen extends api.AbsTreeGen {
import global._
import definitions._
- def rootId(name: Name) = Select(Ident(nme.ROOTPKG), name)
- def rootScalaDot(name: Name) = Select(rootId(nme.scala_) setSymbol ScalaPackage, name)
- def scalaDot(name: Name) = Select(Ident(nme.scala_) setSymbol ScalaPackage, name)
- def scalaAnyRefConstr = scalaDot(tpnme.AnyRef) setSymbol AnyRefClass
- def scalaUnitConstr = scalaDot(tpnme.Unit) setSymbol UnitClass
- def productConstr = scalaDot(tpnme.Product) setSymbol ProductRootClass
- def serializableConstr = scalaDot(tpnme.Serializable) setSymbol SerializableClass
+ def rootId(name: Name) = Select(Ident(nme.ROOTPKG), name)
+ def rootScalaDot(name: Name) = Select(rootId(nme.scala_) setSymbol ScalaPackage, name)
+ def scalaDot(name: Name) = Select(Ident(nme.scala_) setSymbol ScalaPackage, name)
+ def scalaAnnotationDot(name: Name) = Select(scalaDot(nme.annotation), name)
+ def scalaAnyRefConstr = scalaDot(tpnme.AnyRef) setSymbol AnyRefClass
+ def scalaUnitConstr = scalaDot(tpnme.Unit) setSymbol UnitClass
+ def productConstr = scalaDot(tpnme.Product) setSymbol ProductRootClass
+ def serializableConstr = scalaDot(tpnme.Serializable) setSymbol SerializableClass
def scalaFunctionConstr(argtpes: List[Tree], restpe: Tree, abstractFun: Boolean = false): Tree = {
val cls = if (abstractFun)
diff --git a/src/compiler/scala/tools/nsc/javac/JavaParsers.scala b/src/compiler/scala/tools/nsc/javac/JavaParsers.scala
index ca3f3ff635..5c413243e8 100644
--- a/src/compiler/scala/tools/nsc/javac/JavaParsers.scala
+++ b/src/compiler/scala/tools/nsc/javac/JavaParsers.scala
@@ -789,23 +789,24 @@ trait JavaParsers extends ast.parser.ParsersCommon with JavaScanners {
val idefs = members.toList ::: (sdefs flatMap forwarders)
(sdefs, idefs)
}
-
+ def annotationParents = List(
+ gen.scalaAnnotationDot(tpnme.Annotation),
+ Select(javaLangDot(nme.annotation), tpnme.Annotation),
+ gen.scalaAnnotationDot(tpnme.ClassfileAnnotation)
+ )
def annotationDecl(mods: Modifiers): List[Tree] = {
accept(AT)
accept(INTERFACE)
val pos = in.currentPos
val name = identForType()
- val parents = List(scalaDot(tpnme.Annotation),
- Select(javaLangDot(nme.annotation), tpnme.Annotation),
- scalaDot(tpnme.ClassfileAnnotation))
val (statics, body) = typeBody(AT, name)
def getValueMethodType(tree: Tree) = tree match {
case DefDef(_, nme.value, _, _, tpt, _) => Some(tpt.duplicate)
case _ => None
}
- var templ = makeTemplate(parents, body)
+ var templ = makeTemplate(annotationParents, body)
for (stat <- templ.body; tpt <- getValueMethodType(stat))
- templ = makeTemplate(parents, makeConstructor(List(tpt)) :: templ.body)
+ templ = makeTemplate(annotationParents, makeConstructor(List(tpt)) :: templ.body)
addCompanionObject(statics, atPos(pos) {
ClassDef(mods, name, List(), templ)
})
diff --git a/src/library/scala/Predef.scala b/src/library/scala/Predef.scala
index d2aa3a8b34..b84fcc4126 100644
--- a/src/library/scala/Predef.scala
+++ b/src/library/scala/Predef.scala
@@ -468,13 +468,6 @@ object Predef extends LowPriorityImplicits {
implicit def tpEquals[A]: A =:= A = singleton_=:=.asInstanceOf[A =:= A]
}
- // less useful due to #2781
- @deprecated("Use From => To instead", "2.9.0")
- sealed abstract class <%<[-From, +To] extends (From => To) with Serializable
- object <%< {
- implicit def conformsOrViewsAs[A <% B, B]: A <%< B = new (A <%< B) {def apply(x: A) = x}
- }
-
/** A type for which there is always an implicit value.
* @see fallbackCanBuildFrom in Array.scala
*/
diff --git a/src/library/scala/collection/immutable/Range.scala b/src/library/scala/collection/immutable/Range.scala
index 3eb37e99fc..07c8df57ba 100644
--- a/src/library/scala/collection/immutable/Range.scala
+++ b/src/library/scala/collection/immutable/Range.scala
@@ -398,7 +398,4 @@ object Range {
def apply(start: Int, end: Int, step: Int) = NumericRange(start, end, step)
def inclusive(start: Int, end: Int, step: Int) = NumericRange.inclusive(start, end, step)
}
-
- @deprecated("use Range instead", "2.9.0")
- trait ByOne extends Range
}
diff --git a/src/library/scala/package.scala b/src/library/scala/package.scala
index e50f854bc5..064ccd7735 100644
--- a/src/library/scala/package.scala
+++ b/src/library/scala/package.scala
@@ -80,10 +80,6 @@ package object scala {
type Range = scala.collection.immutable.Range
val Range = scala.collection.immutable.Range
- // Migrated from Predef
- @deprecated("Use Thread.currentThread instead", "2.9.0")
- def currentThread = java.lang.Thread.currentThread()
-
// Numeric types which were moved into scala.math.*
type BigDecimal = scala.math.BigDecimal
@@ -127,13 +123,4 @@ package object scala {
type unchecked = annotation.unchecked.unchecked
type volatile = annotation.volatile
*/
-
- @deprecated("use scala.annotation.Annotation instead", "2.9.0")
- type Annotation = scala.annotation.Annotation
- @deprecated("use scala.annotation.ClassfileAnnotation instead", "2.9.0")
- type ClassfileAnnotation = scala.annotation.ClassfileAnnotation
- @deprecated("use scala.annotation.StaticAnnotation instead", "2.9.0")
- type StaticAnnotation = scala.annotation.StaticAnnotation
- @deprecated("use scala.annotation.TypeConstraint instead", "2.9.0")
- type TypeConstraint = scala.annotation.TypeConstraint
}
diff --git a/src/library/scala/reflect/makro/internal/macroImpl.scala b/src/library/scala/reflect/makro/internal/macroImpl.scala
index 86600ba0a1..9cf4d23072 100644
--- a/src/library/scala/reflect/makro/internal/macroImpl.scala
+++ b/src/library/scala/reflect/makro/internal/macroImpl.scala
@@ -2,4 +2,4 @@ package scala.reflect.makro
package internal
/** This type is required by the compiler and <b>should not be used in client code</b>. */
-class macroImpl(val referenceToMacroImpl: Any) extends StaticAnnotation
+class macroImpl(val referenceToMacroImpl: Any) extends annotation.StaticAnnotation
diff --git a/src/library/scala/runtime/package.scala b/src/library/scala/runtime/package.scala
index 9c87baf6a7..e4472b3ea1 100644
--- a/src/library/scala/runtime/package.scala
+++ b/src/library/scala/runtime/package.scala
@@ -1,13 +1,3 @@
package scala
-package object runtime {
- @deprecated("Use `scala.Unit` instead.", "2.9.0") val Unit = scala.Unit
- @deprecated("Use `scala.Boolean` instead.", "2.9.0") val Boolean = scala.Boolean
- @deprecated("Use `scala.Byte` instead.", "2.9.0") val Byte = scala.Byte
- @deprecated("Use `scala.Short` instead.", "2.9.0") val Short = scala.Short
- @deprecated("Use `scala.Char` instead.", "2.9.0") val Char = scala.Char
- @deprecated("Use `scala.Int` instead.", "2.9.0") val Int = scala.Int
- @deprecated("Use `scala.Long` instead.", "2.9.0") val Long = scala.Long
- @deprecated("Use `scala.Float` instead.", "2.9.0") val Float = scala.Float
- @deprecated("Use `scala.Double` instead.", "2.9.0") val Double = scala.Double
-}
+package object runtime { }
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 {