Skip to content

Unexpected Interaction between Named Tuples and Context FunctionsΒ #24058

@joschua-fink

Description

@joschua-fink

Compiler version

3.7.3, 3.7.1

Minimized code

def test(f: String ?=> Unit): Unit = ???

test(a = 1, b = 2)

Output

Compiles. Seems to be equivalent to: test { (a = 1, b = 2) } Implicitly creating a named tuple.

Expectation

Should not Compile.

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