Skip to content

go/types: incorrect error about missing return #11698

Closed
@dvyukov

Description

@dvyukov

gc successfully compiles the following program:

package a
func f() int {
    for {};
    ;
}

while gotype says:

go.go:5: missing return at end of function

go version devel +9b04852 Sat Jul 11 00:08:50 2015 +0000 linux/amd64

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions