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

macro annotations don't expand in repl #18

Closed
xeno-by opened this issue Mar 21, 2014 · 5 comments
Closed

macro annotations don't expand in repl #18

xeno-by opened this issue Mar 21, 2014 · 5 comments
Assignees
Labels
Milestone

Comments

@xeno-by
Copy link
Member

xeno-by commented Mar 21, 2014

http://stackoverflow.com/questions/22549647/whats-the-right-way-to-generate-a-companion-class-de-novo-using-quasiquotes

@xeno-by xeno-by added this to the 2.0.0-final milestone Mar 21, 2014
@xeno-by xeno-by self-assigned this Mar 21, 2014
@xeno-by
Copy link
Member Author

xeno-by commented Mar 21, 2014

That's very strange, because I remember fixing exactly the same bug back then. Probably should make an effort to support partest-style tests for these situations.

@xeno-by
Copy link
Member Author

xeno-by commented Mar 21, 2014

Here's what I get in paradise for 2.11 (well, at least 2.11 isn't susceptible to #13, so we get a clear error message instead of just a silent expansion failure):

scala> @testThing class Thingy { }
<console>:29: error: macro annotation could not be expanded (the most common reason for that is that you need to enable the macro paradise plugin; another possibility is that you try to use macro annotation in the same compilation run that defines it)
       @testThing class Thingy { }
                        ^

Let's see what's going on.

@xeno-by
Copy link
Member Author

xeno-by commented Mar 21, 2014

See efefe00193

@xeno-by
Copy link
Member Author

xeno-by commented Mar 21, 2014

Allright, that fix was about macro annotations defined in repl and not expanding afterwards. This issue is about macro annotations precompiled on classpath and not being picked up by repl.

@xeno-by
Copy link
Member Author

xeno-by commented Mar 21, 2014

Fixed in d9387f0. Note that #19 still remains.

@xeno-by xeno-by closed this as completed Mar 21, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant