Skip to content

Go "exported loop pointer" example is outdated #212

@josharian

Description

@josharian

Go finally fixed the language to make https://github.com/getgrit/stdlib/blob/main/.grit/patterns/go/exported_loop_pointer.md unnecessary--see https://go.dev/blog/loopvar-preview. So assuming go.mod is >= 1.22, probably the right fix is to find and remove all x := x instances. :)

Not sure whether GritQL supports conditioning on the go.mod version.

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