Programmer Question
This produces an anonymous function as expected (f is a function with three arguments):
f(_, _, _)
What I don't understand is why this doesn't compile, instead giving a "missing parameter type" error:
f(_, _, 27)
I need to specify the types of the underscores explicitly. Shouldn't Scala be able to infer their types given that the parameter types of the function f are known?
Find the answer here
No comments:
Post a Comment