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

Problem with imports (wrappers?) #36

Closed
alexarchambault opened this issue Mar 10, 2015 · 9 comments
Closed

Problem with imports (wrappers?) #36

alexarchambault opened this issue Mar 10, 2015 · 9 comments

Comments

@alexarchambault
Copy link
Collaborator

Using the current master branch, I get

Loading Ammonite Repl...

@ load.ivy("com.chuusai" %% "shapeless" % "2.1.0")
:: resolving dependencies :: com.chuusai#shapeless_2.11-caller;working
    ...
res0: Unit = ()

@ import shapeless._
import shapeless._

@ () // Nothing compiles starting from here, whatever the line we enter
Compilation Failed
Main.scala:1136: '}' expected but identifier found.
  ~?>$,
     ^

@ 

(re-formatted/stripped for readability).

The wrapper fails to compile once one imported shapeless._

@lihaoyi
Copy link
Member

lihaoyi commented Mar 10, 2015

Definitely a problem with the wrapper generation, shouldn't be too hard to fix once i have time to take a look

@alexarchambault
Copy link
Collaborator Author

Probably related to #35

@lihaoyi
Copy link
Member

lihaoyi commented Mar 10, 2015

Don't try to fix this yet, I have a bunch of WIP improving the import handling (and tests) that I haven't pushed

@lihaoyi
Copy link
Member

lihaoyi commented Mar 10, 2015

I pushed a576aa4 which is still kinda/sorta WIP but might (maybe?) fix some of these issues. Will take a look later

@alexarchambault
Copy link
Collaborator Author

Hope they don't conflict too much with my last PR... :)

@alexarchambault
Copy link
Collaborator Author

Ok, conflict =|

@alexarchambault
Copy link
Collaborator Author

@lihaoyi Not fixed :-| Last error is now

@ ()
Compilation Failed
Main.scala:1136: '}' expected but identifier found.
  ~?>$ => ~?>$,
     ^

@lihaoyi
Copy link
Member

lihaoyi commented Mar 11, 2015

This particular one looks like an issue with the backtickWrap function not properly wrapping this, and perhaps a problem in importing things we shouldn't import (Private? Synthetic? Who knows?).

In theory we could fall-back to the old behavior and just backtick-wrap everything, but I'd prefer to instead fix-forward and fix the backtick-wrapper. The parboiled parser must be correct and if it's not we should fix it until it is (like @paulp has done for his) and import fixing can't be that hard

@lihaoyi
Copy link
Member

lihaoyi commented Mar 11, 2015

@lihaoyi lihaoyi closed this as completed Mar 11, 2015
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