Skip to content

golang - import cycles not allowed #18

@ORESoftware

Description

@ORESoftware

because golang import cycles are not allowed

if any file references a type from a previous file, it will have to manually look up the type and elaborate the type into a literal:

e.g. this:

package req

import "oredoc/one/entities/bar"

type Headers struct {
}

type Body struct {
 Mip bar.Put
 Mop int
 Map bool
}

will need to become something like:

package req

type Headers struct {
}

type Body struct {
 Mip struct { ... }   // bar.Put
 Mop int
 Map bool
}

add a comment and a link to the other file, so the dev can know what the type is.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions