Skip to content

cmd/compile: error line:col information points to wrong function parameter #28968

@yansal

Description

@yansal

Does this issue reproduce with the latest release?

Yes

What did you do?

https://play.golang.org/p/6PRJL3-x2lO

What did you expect to see?

An error like prog.go:8:2: cannot use bad (type func() func()) as type func() in argument to f

What did you see instead?

prog.go:7:4: cannot use bad (type func() func()) as type func() in argument to f

The compiler error line:col information points to the first argument, but the actual error is the second.

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