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

Allow unquoting names as function expression arguments #8455

Closed
scabug opened this issue Mar 28, 2014 · 2 comments
Closed

Allow unquoting names as function expression arguments #8455

scabug opened this issue Mar 28, 2014 · 2 comments
Assignees
Milestone

Comments

@scabug
Copy link

scabug commented Mar 28, 2014

Currently in order to create an anonymous function with inferred type and given name you need to also unquote an empty type:

scala> val name = TermName("x")
scala> val expr = q"x + 1"
scala> q"($name: ${tq""}) => $expr"
res10: reflect.runtime.universe.Function = ((x) => x.$plus(1))

It might be a good idea to allow unquoting of bare names that would automatically imply setting of empty inferred return type.

@scabug
Copy link
Author

scabug commented Mar 28, 2014

Imported From: https://issues.scala-lang.org/browse/SI-8455?orig=1
Reporter: @densh
Affected Versions: 2.11.0

@scabug scabug added this to the Backlog milestone Apr 7, 2017
@SethTisue
Copy link
Member

closing all quasiquotes tickets; see #10755

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

3 participants