diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2015-02-17 15:18:20 +1000 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2015-02-17 15:19:19 +1000 |
commit | 5a89475526fc91f677d7002b6063bef9e549f0cc (patch) | |
tree | 7b876a8379c0e1199b227cd849f7bc778c444dc2 /src/compiler/scala/tools/nsc/typechecker | |
parent | da49d9a00ec373a0e7f2ffe946a897a65c9b0741 (diff) | |
download | scala-5a89475526fc91f677d7002b6063bef9e549f0cc.tar.gz scala-5a89475526fc91f677d7002b6063bef9e549f0cc.tar.bz2 scala-5a89475526fc91f677d7002b6063bef9e549f0cc.zip |
Cache name for dummy argument used in implicit search
This avoids a minor inefficiency of interning the name on
each implicit candidate. Instead, we follow the usual practice
and use a pre-baked name from `StdNames`.
Diffstat (limited to 'src/compiler/scala/tools/nsc/typechecker')
-rw-r--r-- | src/compiler/scala/tools/nsc/typechecker/Implicits.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Implicits.scala b/src/compiler/scala/tools/nsc/typechecker/Implicits.scala index 71558273a6..0861d58240 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Implicits.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Implicits.scala @@ -609,7 +609,7 @@ trait Implicits { val itree2 = if (!isView) fallback else pt match { case Function1(arg1, arg2) => typed1( - atPos(itree0.pos)(Apply(itree1, List(Ident("<argument>") setType approximate(arg1)))), + atPos(itree0.pos)(Apply(itree1, List(Ident(nme.argument) setType approximate(arg1)))), EXPRmode, approximate(arg2) ) match { |