Skip to content

Capture named argument #108

Description

@pocorall

Is there any way to capture the name of argument currently being assigned?

I tried this but it was not.

case class Foo(bar: String)

def provider(implicit name: sourcecode.Name): String = name.value

Foo(bar = provider) // expected Foo(bar = "bar")

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions