Skip to content

Calling java functions without parentheses results in lambdas instead of compilation errors #16820

Closed
@scf37

Description

@scf37

Compiler version

3.1.3 and later

Minimized code

val p = java.nio.file.Paths.get(".")
println(p.toRealPath)

Output

Playground$$$Lambda$20996/0x00000008047106c8@3cdbaf1c

Expectation

Compilation error (like before) or file path (like what I want). Calling java functions without parentheses was my good habit that suddenly turned out to be bad one.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions