diff options
author | paltherr <paltherr@epfl.ch> | 2003-09-30 17:01:13 +0000 |
---|---|---|
committer | paltherr <paltherr@epfl.ch> | 2003-09-30 17:01:13 +0000 |
commit | 20918420a89091ff5e42a791867a24c6889022c2 (patch) | |
tree | fdafff3590c9cfdea17ddeb23809e9e13e45b4f2 /test/files/run | |
parent | 154770da0b6db84af6a0e819c4855511e35b7e5c (diff) | |
download | scala-20918420a89091ff5e42a791867a24c6889022c2.tar.gz scala-20918420a89091ff5e42a791867a24c6889022c2.tar.bz2 scala-20918420a89091ff5e42a791867a24c6889022c2.zip |
- Renamed bug 135 into 168
- Added new bug 135
Diffstat (limited to 'test/files/run')
-rw-r--r-- | test/files/run/bugs.scala | 34 |
1 files changed, 27 insertions, 7 deletions
diff --git a/test/files/run/bugs.scala b/test/files/run/bugs.scala index 57b9ff8a08..873006592d 100644 --- a/test/files/run/bugs.scala +++ b/test/files/run/bugs.scala @@ -6,16 +6,20 @@ //############################################################################ // Bug 135 -class Bug135Foo { - class Bar; - def foo = new Bar; -} +object Bug135Test { + + import scala.collection.immutable.TreeMap; + import scala.collection.immutable.Order; -object Bug135Test { def main(args: Array[String]): Unit = { - (new Bug135Foo).foo; - () + val intOrder = + new Order((x:int,y:int) => x < y, (x:int,y:int) => x == y); + val myMap:TreeMap[int,String] = new TreeMap(intOrder); + val map1 = myMap + 42 -> "The answer"; + if (map1.get(42) != Some("The answer")) + Console.println("KO: " + map1.get(42)); } + } //############################################################################ @@ -35,12 +39,28 @@ object Bug167Test { } //############################################################################ +// Bug 168 + +class Bug168Foo { + class Bar; + def foo = new Bar; +} + +object Bug168Test { + def main(args: Array[String]): Unit = { + (new Bug168Foo).foo; + () + } +} + +//############################################################################ // Main object Test { def main(args: Array[String]): Unit = { Bug135Test.main(args); Bug167Test.main(args); + Bug168Test.main(args); } } |