Skip to content

Upgrading to modern Go #1209

@danielorbach

Description

@danielorbach

Hi team,

I’m preparing a contribution to the repository and would like to ask about updating the go directive in go.mod.

Currently, the module specifies go1.12, but newer Go versions introduce several language and tooling improvements that would simplify development and testing. For example:

  • go1.16: Introduced go:embed, which I can use for embedding test data.
  • go1.18: Introduced generics, which would simplify comparisons (e.g., I compare []gopacket.LayerType slices) and reduce boilerplate.
  • go1.19: Improved doc comment formatting (e.g., link parsing), which affects how documentation is rendered on pkg.go.dev, so I should know whether to use link syntax or not.

Would you be open to updating the module’s Go version, or accepting contributions that use features introduced in later versions? Alternatively, is there a minimum Go version you’d prefer contributors target?

Thanks for your time.

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