def func(x: Int)(y :Int)(z : Int) : Int = x + y + z
val a = func(1)
fails with the error
error: missing argument list for method func
Unapplied methods are only converted to functions when a function type is expected.
You can make this conversion explicit by writing `func _` or `func(_)(_)(_)` instead of `func`.
this has little to do with the REPL, and fails with directly compiled code as well. Just like the error message states, a function type needs to be expected, which is not the case. You can obtain the desired behaviour in one of two ways:
Explicitly give a function type to a, i.e. val a: Int => Int => Int = func(1)
Suggest that a has a function type by adding an underscore, i.e. val a = func(1) _
Both options reflect that a has a function type.
Essentially, there is a difference between a properly curried function f: Int => Int => Int and a method f(x: Int)(y: Int): Int, and the conversion from the latter to the former only works, when a hint is supplied.