I created this function on Scala REPL
scala> val multiDouble = (input :Double) =>
| {
| val toMulti = 2;
| toMulti * input
| }: Double
And the output is val multiDouble: Double => Double = Lambda$1351/1709493124@7b44bfb8
For what I've studied it should be val multiDouble: Double => Double = <function01>
I don't understand why Scala REPL prints Lambda$1351/1709493124@7b44bfb8 and not <function01>.
In Scala 2.11- functions are printed as
<function01>, in Scala 2.12+ they are printed asLambda$.../...@...2.12 lambdas have different
toStringhttps://github.com/scala/scala-dev/issues/67Scala 2.12.0: output of assigning a function literal to a value
datatype of anonymous function vs named function in scala
https://contributors.scala-lang.org/t/functionns-tostring-should-show-the-types/2572