Skip to content

cmd/godoc: Nested functions on embedded types are only shown 1 level deep. #9762

Closed
@klauspost

Description

@klauspost

Test case: http://play.golang.org/p/9oz7e7AKzd

In the example above A embeds b which embeds c. There are public functions on b, which is shown correctly in godoc as belonging to A. However, it seems like godoc only searches 1 level deep, and functions on c are not shown even though they are valid for calls by the compiler.

Reproducible on 1.4.1 and 1.3.3.

Real life example: source / godoc. A specific query type includes "geoJSONQuery" which includes "query", and I would like to have the functions on "query" to show up. I would however prefer not to expose any of the internal types since they aren't useful themselves.

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