-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Range position incorrect for infix, braced application #8859
Comments
Imported From: https://issues.scala-lang.org/browse/SI-8859?orig=1 |
@retronym said: |
@gkossakowski said: |
@retronym said (edited on Sep 24, 2014 12:59:03 PM UTC): The bigger question in my mind is whether the introduction of the new, transient AST node |
@gkossakowski said: |
@dwijnand said: |
Possibly related: object Foo {
def apply(t : Any)(block: => Unit) : Unit = {}
def foo(t : Any)(block: => Unit) : Unit = {}
}
object Test {
Foo(1){} //OK
Foo foo(1) {} //Error: Int(1) does not take parameters
Foo.foo(1) {} //OK
}
Where the applications are parsed as: Foo(1)(());
Foo.foo(1(()));
Foo.foo(1)(()) |
I created a scastie link with the error and parser printing. |
I think the error is correct, as it's
Are they still making puzzlers? |
There's a related (edit: or not) position ticket #12074 I was just grepping for a good example of a confusing "does not take parameters", because there is a dotty ticket about how helpful an error message should be. |
As discovered and investigated by [~ajozwik]: scala/scala#3991
The text was updated successfully, but these errors were encountered: