diff options
author | Paul Phillips <paulp@improving.org> | 2012-12-12 12:27:43 -0800 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2012-12-12 12:27:43 -0800 |
commit | cad4c1a7a70536f285623be2434f72ee5bbf601d (patch) | |
tree | 0cf010694d360d5ec8e82fdfb2599acc8de80f58 /test/files | |
parent | 00eb7af51d446b3e6aa963ad14b2a4d93dd4c69c (diff) | |
parent | e77db05f7306aeb80c46df9c8d76dfd739a97e6a (diff) | |
download | scala-cad4c1a7a70536f285623be2434f72ee5bbf601d.tar.gz scala-cad4c1a7a70536f285623be2434f72ee5bbf601d.tar.bz2 scala-cad4c1a7a70536f285623be2434f72ee5bbf601d.zip |
Merge pull request #1743 from paulp/pr/shared-trees
reduce sharing between trees
Diffstat (limited to 'test/files')
-rw-r--r-- | test/files/run/t0091.check | 1 | ||||
-rw-r--r-- | test/files/run/t0091.scala | 15 |
2 files changed, 10 insertions, 6 deletions
diff --git a/test/files/run/t0091.check b/test/files/run/t0091.check index 7ed6ff82de..fd3c81a4d7 100644 --- a/test/files/run/t0091.check +++ b/test/files/run/t0091.check @@ -1 +1,2 @@ 5 +5 diff --git a/test/files/run/t0091.scala b/test/files/run/t0091.scala index eaddde0dbf..45235eb77b 100644 --- a/test/files/run/t0091.scala +++ b/test/files/run/t0091.scala @@ -4,10 +4,13 @@ object C extends B { object m extends A { def x = 5 } } object Test { - // The type annotation here is necessary, otherwise - // the compiler would reference C$m$ directly. - def o : B = C - def main(argv : Array[String]) : Unit = { - println(o.m.x) - } + // The type annotation here is necessary, otherwise + // the compiler would reference C$m$ directly. + def o1 : B = C + def o2 = C + + def main(argv : Array[String]) : Unit = { + println(o1.m.x) + println(o2.m.x) + } } |