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

#9 Add Caller #28

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

izhangzhihao
Copy link

No description provided.

case class Caller[A](value: A)
object Caller {
implicit def generate: Caller[_] = macro impl
def impl(c: whitebox.Context): c.Tree = {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this looks like it could work as blackbox

@@ -105,6 +106,15 @@ object Pkg extends SourceCompanion[String, Pkg](new Pkg(_)){
def impl(c: Compat.Context): c.Expr[Pkg] = Impls.enclosing[Pkg](c)(_.isPackage)
}

case class Caller[A](value: A)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not keen on this being parametric, it would be best if it was a String to avoid leaking runtime information.

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

Successfully merging this pull request may close these issues.

2 participants