You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@paulp said:
Presumably he thinks "(new A)Int" ought to say "res0: 1" instead of ":1: error: ';' expected but '[' found."
I agree in principle, and trunk already has several fixes allowing for apply methods to be called more flexibly, for instance this doesn't work in 2.7.3:
scala>deffoo(x: Int, y: Int) = x + y
foo: (Int,Int)Int
scala> (foo _)(5, 10)
res0:Int=15
However this would represent a rather more significant change to the parser and I'm not really convinced it's a good idea given that it works if you let the type argument be inferred or if you call apply explicitly.
I cannot call generic apply call for new instances. But according to spec it must run well:
The text was updated successfully, but these errors were encountered: