Skip to content
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

2.8 regression: "@ _*" fails #3480

Closed
scabug opened this issue May 26, 2010 · 8 comments
Closed

2.8 regression: "@ _*" fails #3480

scabug opened this issue May 26, 2010 · 8 comments
Assignees

Comments

@scabug
Copy link

scabug commented May 26, 2010

Using both, eclipse plugin as well as scala, from today's revision (2.8.0.r22036-b20100526020129).

The valid use of "@ _*" is correctly compiled by scala but fails to be parsed in the eclipse plugin.
Example:

object RemainingArgs {

  def main(args: Array[String]): Unit = {  }
  
  	val aString = "Eclipse plugin cannot not handle this"
  	val Array( who, what @ _* ) = aString split (" ")
  	
}
@scabug
Copy link
Author

scabug commented May 26, 2010

Imported From: https://issues.scala-lang.org/browse/SI-3480?orig=1
Reporter: Lukas Pustina (lukas.pustina)

@scabug
Copy link
Author

scabug commented May 26, 2010

Atsuhiko Yamanaka (ymnk) said:
I have also encountered the similar problem with scalac and on REPL,

$$ scala
Welcome to Scala version 2.8.0.r22036-b20100526020129 (Java HotSpot(TM) Client VM, Java 1.6.0_16).
Type in expressions to have them evaluated.
Type :help for more information.

scala> val List(x@_*)=List(0)
<console>:1: error: illegal start of simple pattern
       val List(x@_*)=List(0)

@scabug
Copy link
Author

scabug commented May 26, 2010

Atsuhiko Yamanaka (ymnk) said:
It seems to me that this problem has been caused by Changeset r21973.

@scabug
Copy link
Author

scabug commented May 26, 2010

@milessabin said:
Also, for future reference, please note that Eclipse-specific bugs should be filed in their own [http://scala-ide.assembla.com/wiki/show/scala-ide/Bug_Reporting issue tracker].

@scabug
Copy link
Author

scabug commented May 26, 2010

Lukas Pustina (lukas.pustina) said:
Replying to [comment:3 milessabin]:

Also, for future reference, please note that Eclipse-specific bugs should be filed in their own [http://scala-ide.assembla.com/wiki/show/scala-ide/Bug_Reporting issue tracker].

ACK. Besides, it would be helpful to change the link on https://lampsvn.epfl.ch/trac/scala "Components: Tickets about, Scala IDE for Eclipse" to point to the mentioned link.

@scabug
Copy link
Author

scabug commented May 26, 2010

@milessabin said:
Replying to [comment:4 lukas.pustina]: Good catch ... done.

@scabug
Copy link
Author

scabug commented Jun 2, 2010

@SethTisue said:
this isn't specific to the Eclipse plugin. the 2.8.0.RC3 command line compiler gives:

  ~> scalac28 S.scala
S.scala:6: error: illegal start of simple pattern
  	val Array( who, what @ _* ) = aString split (" ")
                                  ^

@scabug
Copy link
Author

scabug commented Jun 4, 2010

@paulp said:
(In r22159) Reverts r21973, the patch I characterized as "hacky but no-risk"
in my commit message, for causing #3480. Closes #3480. I'd say
no review but who can trust a guy who throws around "no risk"
with such abandon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants