In Scala REPL kann man Werttypen finden:Scala REPL: Wie funktioniert der Funktionstyp?
scala> val x = 1
x: Int = 1
scala> :t x
Int
Doch Scala REPL zeigt nicht die Typinformationen für Funktionen:
scala> def inc(x:Int) = x + 1
inc: (x: Int)Int
scala> :t inc
<console>:9: error: missing arguments for method inc;
follow this method with `_' if you want to treat it as a partially applied function
inc
^
<console>:9: error: missing arguments for method inc;
follow this method with `_' if you want to treat it as a partially applied function
inc
^
Wie Funktion Typ in Scala REPL finden?
Wie wäre es zu tun, was sagt es in der Fehlermeldung? – folone
möglich duplicate von [this] (http://stackoverflow.com/questions/15583551/type-information-in-the-scala-repl) –