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

sometimes cannot splice lists of trees into a quasiquote #6840

Closed
scabug opened this issue Dec 18, 2012 · 3 comments
Closed

sometimes cannot splice lists of trees into a quasiquote #6840

scabug opened this issue Dec 18, 2012 · 3 comments
Assignees
Milestone

Comments

@scabug
Copy link

scabug commented Dec 18, 2012

val q"class $name extends Liftable { ..$body }" = tree
val newdefs = body collect { ... }
q"class $name extends AnyRef { ..${body ++ newdefs} }"

In this snippet above, body ++ newdefs doesn't work unless adorned in a toList.

@scabug
Copy link
Author

scabug commented Dec 18, 2012

Imported From: https://issues.scala-lang.org/browse/SI-6840?orig=1
Reporter: @xeno-by
Affected Versions: 2.11.0-M4
See #6155

@scabug
Copy link
Author

scabug commented Oct 2, 2013

@densh said:
The problem is that typechecking with Any as expected type (declared type of the argument of the quasiquote) causes body ++ newdefs to be typechecked as Any.

This seems to be related to #6155.

@scabug
Copy link
Author

scabug commented Oct 19, 2013

@densh said:
scala/scala#3059

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

No branches or pull requests

2 participants