Skip to content

Context queries: Ambiguity between given argument and call to apply() #5966

Closed
@eichholz

Description

@eichholz

Given a function definition

def foo = given (v: Int) => (x: Int) => v + x
implied myInt for Int = 4

Both foo.apply(7) and (foo given 4)(7) works fine, but foo(7) fails to compile (method apply in trait ImplicitFunction1 does not take more parameters).

Tested with Dotty 0.13.0-RC1 and 0.14.0-bin-20190220-60c4bf8-NIGHTLY.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions