diff options
author | Paul Phillips <paulp@improving.org> | 2009-11-18 22:06:03 +0000 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2009-11-18 22:06:03 +0000 |
commit | ae024cebd4a41339039f3df91c8aa4a02522594f (patch) | |
tree | 07c5e3a27ce4636f76eb73fe43353fc6c6aa0362 /test/files | |
parent | 536955e1afd68ac6f99f0347fa14a58ab47cb958 (diff) | |
download | scala-ae024cebd4a41339039f3df91c8aa4a02522594f.tar.gz scala-ae024cebd4a41339039f3df91c8aa4a02522594f.tar.bz2 scala-ae024cebd4a41339039f3df91c8aa4a02522594f.zip |
Finally completed the incredibly tedious task o...
Finally completed the incredibly tedious task of removing the lower case
primitive aliases from Predef. Had to rebuild msil.jar along the way.
Diffstat (limited to 'test/files')
-rw-r--r-- | test/files/neg/bug563.scala | 2 | ||||
-rw-r--r-- | test/files/neg/bug700.check | 2 | ||||
-rw-r--r-- | test/files/neg/bug700.scala | 2 | ||||
-rw-r--r-- | test/files/neg/bug910.check | 4 | ||||
-rw-r--r-- | test/files/neg/bug910.scala | 2 | ||||
-rw-r--r-- | test/files/neg/constrs.check | 2 | ||||
-rw-r--r-- | test/files/neg/constrs.scala | 2 | ||||
-rw-r--r-- | test/files/neg/gadts1.scala | 8 | ||||
-rw-r--r-- | test/files/neg/implicits.check | 2 | ||||
-rw-r--r-- | test/files/neg/implicits.scala | 4 | ||||
-rw-r--r-- | test/files/neg/overload.check | 2 | ||||
-rw-r--r-- | test/files/neg/overload.scala | 2 | ||||
-rw-r--r-- | test/files/neg/t0218.scala | 2 | ||||
-rw-r--r-- | test/files/neg/viewtest.scala | 16 | ||||
-rw-r--r-- | test/files/pos/bug0091.scala | 2 | ||||
-rw-r--r-- | test/files/pos/bug1075.scala | 2 | ||||
-rw-r--r-- | test/files/pos/bug287.scala | 2 | ||||
-rw-r--r-- | test/files/pos/nested2.scala | 2 | ||||
-rw-r--r-- | test/files/pos/switchUnbox.scala | 2 | ||||
-rw-r--r-- | test/files/pos/t1164.scala | 2 | ||||
-rw-r--r-- | test/files/run/Course-2002-09.scala | 8 | ||||
-rw-r--r-- | test/files/run/bug627.scala | 2 | ||||
-rw-r--r-- | test/files/run/unapply.scala | 2 | ||||
-rw-r--r-- | test/files/run/unapplyArray.scala | 2 |
24 files changed, 39 insertions, 39 deletions
diff --git a/test/files/neg/bug563.scala b/test/files/neg/bug563.scala index d8e026e656..624b83b1fa 100644 --- a/test/files/neg/bug563.scala +++ b/test/files/neg/bug563.scala @@ -1,7 +1,7 @@ object Test { def map[A,R](a : List[A], f : A => R) : List[R] = a.map(f); - def split(sn : Iterable[List[Cell[int]]]) : unit = + def split(sn : Iterable[List[Cell[Int]]]) : Unit = for (n <- sn) map(n,ptr => new Cell(ptr.elem)); } diff --git a/test/files/neg/bug700.check b/test/files/neg/bug700.check index 33a67e5094..5c2854069c 100644 --- a/test/files/neg/bug700.check +++ b/test/files/neg/bug700.check @@ -1,4 +1,4 @@ bug700.scala:6: error: method foobar in trait Foo is accessed from super. It may not be abstract unless it is overridden by a member declared `abstract' and `override' - def foobar: unit = super.foobar + def foobar: Unit = super.foobar ^ one error found diff --git a/test/files/neg/bug700.scala b/test/files/neg/bug700.scala index 7477bb54f6..b08c8b5529 100644 --- a/test/files/neg/bug700.scala +++ b/test/files/neg/bug700.scala @@ -3,7 +3,7 @@ trait Foo { } trait Bar extends Foo { - def foobar: unit = super.foobar + def foobar: Unit = super.foobar } // the following definition breaks the compiler diff --git a/test/files/neg/bug910.check b/test/files/neg/bug910.check index fe4ad4fca4..2bc2d986fa 100644 --- a/test/files/neg/bug910.check +++ b/test/files/neg/bug910.check @@ -1,6 +1,6 @@ bug910.scala:4: error: type mismatch; found : Seq[Char] - required: scala.Seq[int] - val y: Seq[int] = rest + required: scala.Seq[Int] + val y: Seq[Int] = rest ^ one error found diff --git a/test/files/neg/bug910.scala b/test/files/neg/bug910.scala index 2f28ea408f..540ee7001d 100644 --- a/test/files/neg/bug910.scala +++ b/test/files/neg/bug910.scala @@ -1,7 +1,7 @@ object RegExpTest1 extends Application { def co(x: Seq[Char]) = x match { case Seq('s','c','a','l','a', rest @ _*) => - val y: Seq[int] = rest + val y: Seq[Int] = rest y } } diff --git a/test/files/neg/constrs.check b/test/files/neg/constrs.check index 3524709785..4f4a12bc13 100644 --- a/test/files/neg/constrs.check +++ b/test/files/neg/constrs.check @@ -8,7 +8,7 @@ constrs.scala:10: error: called constructor's definition must precede calling co def this() = this("abc") ^ constrs.scala:12: error: called constructor's definition must precede calling constructor's definition - def this(x: boolean) = this(x) + def this(x: Boolean) = this(x) ^ constrs.scala:16: error: type mismatch; found : Int(1) diff --git a/test/files/neg/constrs.scala b/test/files/neg/constrs.scala index 969f593a2d..016df098f0 100644 --- a/test/files/neg/constrs.scala +++ b/test/files/neg/constrs.scala @@ -9,7 +9,7 @@ object test { class Foo(x: Int) { def this() = this("abc") def this(x: String) = this(1) - def this(x: boolean) = this(x) + def this(x: Boolean) = this(x) } class Bar[a](x: a) { diff --git a/test/files/neg/gadts1.scala b/test/files/neg/gadts1.scala index 67aef4f2d9..07200ff7aa 100644 --- a/test/files/neg/gadts1.scala +++ b/test/files/neg/gadts1.scala @@ -1,8 +1,8 @@ object Test{ abstract class Number -case class Int(n: int) extends Number -case class Double(d: double) extends Number +case class Int(n: scala.Int) extends Number +case class Double(d: scala.Double) extends Number trait Term[+a] case class Cell[a](var x: a) extends Term[a] @@ -10,7 +10,7 @@ case class NumTerm(val n: Number) extends Term[Number] class IntTerm(n: Int) extends NumTerm(n) with Term[Int] -def f[a](t:Term[a], c:Cell[a]): unit = +def f[a](t:Term[a], c:Cell[a]): Unit = t match { case NumTerm(n) => c.x = Double(1.0) } @@ -18,7 +18,7 @@ def f[a](t:Term[a], c:Cell[a]): unit = val x:Term[Number] = NumTerm(Int(5)) -def main(args: Array[String]): unit = { +def main(args: Array[String]): Unit = { val cell = Cell[Int](Int(6)) Console.println(cell) f[Int](new IntTerm(Int(5)), cell) diff --git a/test/files/neg/implicits.check b/test/files/neg/implicits.check index d94e1f27f2..337560f423 100644 --- a/test/files/neg/implicits.check +++ b/test/files/neg/implicits.check @@ -3,7 +3,7 @@ implicits.scala:21: error: type mismatch; required: ?{val +: ?} Note that implicit conversions are not applicable because they are ambiguous: both method any2plus in object Sub of type (x: Any)Sub.Plus - and method pos2int in object Super of type (p: Pos)int + and method pos2int in object Super of type (p: Pos)Int are possible conversion functions from Pos to ?{val +: ?} f(p+1) ^ diff --git a/test/files/neg/implicits.scala b/test/files/neg/implicits.scala index be85029660..846591e22d 100644 --- a/test/files/neg/implicits.scala +++ b/test/files/neg/implicits.scala @@ -3,7 +3,7 @@ class Pos class Super object Super { - implicit def pos2int(p: Pos): int = 0 + implicit def pos2int(p: Pos): Int = 0 } object Sub extends Super { @@ -17,7 +17,7 @@ object Test { import Super._ import Sub._ val p = new Pos - def f(x: int): int = x + def f(x: Int): Int = x f(p+1) } diff --git a/test/files/neg/overload.check b/test/files/neg/overload.check index 0faa97adb1..abfabaf3f2 100644 --- a/test/files/neg/overload.check +++ b/test/files/neg/overload.check @@ -1,6 +1,6 @@ overload.scala:10: error: ambiguous reference to overloaded definition, both method f in class D of type (x: Any)Unit -and method f in class C of type (x: int)Unit +and method f in class C of type (x: Int)Unit match argument types (Int) (new D).f(1) ^ diff --git a/test/files/neg/overload.scala b/test/files/neg/overload.scala index 311ea3874b..6ad911e90e 100644 --- a/test/files/neg/overload.scala +++ b/test/files/neg/overload.scala @@ -1,5 +1,5 @@ class C { - def f(x: int) {} + def f(x: Int) {} } class D extends C { diff --git a/test/files/neg/t0218.scala b/test/files/neg/t0218.scala index 282e85e814..319be82a7a 100644 --- a/test/files/neg/t0218.scala +++ b/test/files/neg/t0218.scala @@ -6,7 +6,7 @@ trait APQ { type PP = P - def pq(numQueens: int, numRows: int) : List[Placement] = { + def pq(numQueens: Int, numRows: Int) : List[Placement] = { List(new PP) } } diff --git a/test/files/neg/viewtest.scala b/test/files/neg/viewtest.scala index 778e672d91..5e7d624d23 100644 --- a/test/files/neg/viewtest.scala +++ b/test/files/neg/viewtest.scala @@ -12,13 +12,13 @@ trait Ordered[+a] { */ def compareTo [b >: a <% Ordered[b]](that: b): Int - def < [b >: a <% Ordered[b]](that: b): boolean = (this compareTo that) < 0 + def < [b >: a <% Ordered[b]](that: b): Boolean = (this compareTo that) < 0 - def > [b >: a <% Ordered[b]](that: b): boolean = (this compareTo that) > 0 + def > [b >: a <% Ordered[b]](that: b): Boolean = (this compareTo that) > 0 - def <= [b >: a <% Ordered[b]](that: b): boolean = (this compareTo that) <= 0 + def <= [b >: a <% Ordered[b]](that: b): Boolean = (this compareTo that) <= 0 - def >= [b >: a <% Ordered[b]](that: b): boolean = (this compareTo that) >= 0 + def >= [b >: a <% Ordered[b]](that: b): Boolean = (this compareTo that) >= 0 } @@ -30,9 +30,9 @@ object O { case _ => -(y compareTo x) } } - implicit def view2(x: char): Ordered[char] = new Ordered[char] { - def compareTo [b >: char <% Ordered[b]](y: b): Int = y match { - case y1: char => x - y1 + implicit def view2(x: Char): Ordered[Char] = new Ordered[Char] { + def compareTo [b >: Char <% Ordered[b]](y: b): Int = y match { + case y1: Char => x - y1 case _ => -(y compareTo x) } } @@ -106,7 +106,7 @@ object Test { Console.println(t.elements) } { - var t: Tree[List[char]] = Empty + var t: Tree[List[Char]] = Empty for (s <- args) { t = t insert toCharList(s) } diff --git a/test/files/pos/bug0091.scala b/test/files/pos/bug0091.scala index 54c821b41c..d491b7cfb9 100644 --- a/test/files/pos/bug0091.scala +++ b/test/files/pos/bug0091.scala @@ -1,6 +1,6 @@ class Bug { def main(args: Array[String]) = { var msg: String = null; // no bug if "null" instead of "_" - val f: PartialFunction[Any, unit] = { case 42 => msg = "coucou" }; + val f: PartialFunction[Any, Unit] = { case 42 => msg = "coucou" }; } } diff --git a/test/files/pos/bug1075.scala b/test/files/pos/bug1075.scala index 936ef72272..0f518b24db 100644 --- a/test/files/pos/bug1075.scala +++ b/test/files/pos/bug1075.scala @@ -5,7 +5,7 @@ class Directory(var dir_ : String) } dir_ = dir_.replaceAll("/{2,}", "/") - def this(serialized : Array[byte]) = { + def this(serialized : Array[Byte]) = { this(new String(serialized, "UTF-8")) } diff --git a/test/files/pos/bug287.scala b/test/files/pos/bug287.scala index 81a01951b2..8e5e8831c1 100644 --- a/test/files/pos/bug287.scala +++ b/test/files/pos/bug287.scala @@ -1,7 +1,7 @@ object testBuf { class mystream extends java.io.BufferedOutputStream(new java.io.FileOutputStream("/dev/null")) { def w( x:String ):Unit = { - val foo = new Array[byte](2); + val foo = new Array[Byte](2); // write( byte[] ) is defined in FilterOutputStream, the superclass of BufferedOutputStream super.write( foo ); // error diff --git a/test/files/pos/nested2.scala b/test/files/pos/nested2.scala index 302688a0ef..421ea6facf 100644 --- a/test/files/pos/nested2.scala +++ b/test/files/pos/nested2.scala @@ -5,5 +5,5 @@ class C[A] { object Test { val x = new C[String] - val y: C[String]#D[int] = new x.D[int] + val y: C[String]#D[Int] = new x.D[Int] } diff --git a/test/files/pos/switchUnbox.scala b/test/files/pos/switchUnbox.scala index a97bff5521..4f5467de29 100644 --- a/test/files/pos/switchUnbox.scala +++ b/test/files/pos/switchUnbox.scala @@ -2,7 +2,7 @@ // that contains -Xsqueeze:on // object Foo { - var xyz: (int, String) = (1, "abc") + var xyz: (Int, String) = (1, "abc") xyz._1 match { case 1 => Console.println("OK") case 2 => Console.println("OK") diff --git a/test/files/pos/t1164.scala b/test/files/pos/t1164.scala index 3acda88ba9..b238bf54d9 100644 --- a/test/files/pos/t1164.scala +++ b/test/files/pos/t1164.scala @@ -15,7 +15,7 @@ object test { // Try the same thing as above but use function as arguemnt to Bar // constructor - type FunIntToA [a] = (int) => a + type FunIntToA [a] = (Int) => a class Bar[a] (var f: FunIntToA[a]) object Bar { diff --git a/test/files/run/Course-2002-09.scala b/test/files/run/Course-2002-09.scala index fac39e0841..384a91efd8 100644 --- a/test/files/run/Course-2002-09.scala +++ b/test/files/run/Course-2002-09.scala @@ -81,7 +81,7 @@ class Constant(q: Quantity, v: Double) extends Constraint { class Probe(name: String, q: Quantity) extends Constraint { def newValue: Unit = printProbe(q.getValue); def dropValue: Unit = printProbe(None); - private def printProbe(v: Option[double]) { + private def printProbe(v: Option[Double]) { val vstr = v match { case Some(x) => x.toString() case None => "?" @@ -103,7 +103,7 @@ class Quantity() { if (v != v1) error("Error! contradiction: " + v + " and " + v1); case None => informant = setter; value = Some(v); - for (val c <- constraints; !(c == informant)) { + for (c <- constraints; if !(c == informant)) { c.newValue; } } @@ -112,7 +112,7 @@ class Quantity() { def forgetValue(retractor: Constraint): Unit = { if (retractor == informant) { value = None; - for (val c <- constraints; !(c == informant)) c.dropValue; + for (c <- constraints; if !(c == informant)) c.dropValue; } } def forgetValue: Unit = forgetValue(NoConstraint); @@ -258,7 +258,7 @@ object M2 { }; } - def show(x: Option[int], y: Option[Int], z: Option[int]) = { + def show(x: Option[Int], y: Option[Int], z: Option[Int]) = { Console.print("a = " +set(a,x)+ ", b = " +set(b,y)+ ", c = " +set(c,z)); Console.println(" => " + a.str + " * " + b.str + " = " + c.str); a.forgetValue; b.forgetValue; c.forgetValue; diff --git a/test/files/run/bug627.scala b/test/files/run/bug627.scala index 6415694ffe..ecaf150741 100644 --- a/test/files/run/bug627.scala +++ b/test/files/run/bug627.scala @@ -1,6 +1,6 @@ object Test { def main(args: Array[String]) { - val s: Seq[int] = Array(1, 2, 3, 4) + val s: Seq[Int] = Array(1, 2, 3, 4) println(s) } } diff --git a/test/files/run/unapply.scala b/test/files/run/unapply.scala index 72a4b0ac64..acbce58d35 100644 --- a/test/files/run/unapply.scala +++ b/test/files/run/unapply.scala @@ -111,7 +111,7 @@ object StreamFoo extends TestCase("unapply for Streams") with Assert { case Stream.cons(hd, tl) => hd + sum(tl) } override def runTest { - val str: Stream[int] = Stream.fromIterator(List(1,2,3).iterator) + val str: Stream[Int] = Stream.fromIterator(List(1,2,3).iterator) assertEquals(sum(str), 6) } } diff --git a/test/files/run/unapplyArray.scala b/test/files/run/unapplyArray.scala index bf6582dadf..bf7c9e2300 100644 --- a/test/files/run/unapplyArray.scala +++ b/test/files/run/unapplyArray.scala @@ -1,7 +1,7 @@ object Test { def main(args:Array[String]): Unit = { val z = Array(1,2,3,4) - val zs: Seq[int] = z + val zs: Seq[Int] = z val za: Any = z /* |