diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2012-07-07 09:24:50 +0200 |
---|---|---|
committer | Adriaan Moors <adriaan.moors@epfl.ch> | 2012-07-14 17:46:45 +0200 |
commit | a3bf34563d718f19ad02ff9ac5a2a1cec865aa24 (patch) | |
tree | 0725474dd1873e173a60508c420d031c7347d8c2 /test/files/run/t6028.check | |
parent | 32dc7e80698c83947bf4b74f6eadd385a06f5b09 (diff) | |
download | scala-a3bf34563d718f19ad02ff9ac5a2a1cec865aa24.tar.gz scala-a3bf34563d718f19ad02ff9ac5a2a1cec865aa24.tar.bz2 scala-a3bf34563d718f19ad02ff9ac5a2a1cec865aa24.zip |
SI-6028 Avoid needless symbol renaming in lambdalift.
Preserve names of all referenced free vars. Only the proxy symbols
have the fresh names.
The resulting natural beauty is evident in the diff of t6028.check.
This subsumes the treatment in 0e170e4b that ensured named parameter
calls cannot see mangled names; pos/t6028 confirms as much.
Diffstat (limited to 'test/files/run/t6028.check')
-rw-r--r-- | test/files/run/t6028.check | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/test/files/run/t6028.check b/test/files/run/t6028.check index 6c9930b503..dca61115ad 100644 --- a/test/files/run/t6028.check +++ b/test/files/run/t6028.check @@ -8,20 +8,20 @@ package <empty> { }; private[this] val field: Int = 0; <stable> <accessor> def field(): Int = T.this.field; - def foo(methodParam$1: Int): Function0 = { - val methodLocal$1: Int = 0; + def foo(methodParam: Int): Function0 = { + val methodLocal: Int = 0; { - (new anonymous class $anonfun$foo$1(T.this, methodParam$1, methodLocal$1): Function0) + (new anonymous class $anonfun$foo$1(T.this, methodParam, methodLocal): Function0) } }; - def bar(barParam$1: Int): Object = { - @volatile var MethodLocalObject$module$1: scala.runtime.VolatileObjectRef = new scala.runtime.VolatileObjectRef(<empty>); - T.this.MethodLocalObject$1(barParam$1, MethodLocalObject$module$1) + def bar(barParam: Int): Object = { + @volatile var MethodLocalObject$module: scala.runtime.VolatileObjectRef = new scala.runtime.VolatileObjectRef(<empty>); + T.this.MethodLocalObject$1(barParam, MethodLocalObject$module) }; - def tryy(tryyParam$1: Int): Function0 = { - var tryyLocal$1: scala.runtime.IntRef = new scala.runtime.IntRef(0); + def tryy(tryyParam: Int): Function0 = { + var tryyLocal: scala.runtime.IntRef = new scala.runtime.IntRef(0); { - (new anonymous class $anonfun$tryy$1(T.this, tryyParam$1, tryyLocal$1): Function0) + (new anonymous class $anonfun$tryy$1(T.this, tryyParam, tryyLocal): Function0) } }; @SerialVersionUID(0) final <synthetic> class $anonfun$foo$1 extends scala.runtime.AbstractFunction0$mcI$sp with Serializable { |