Allocate map outside loop

Proprietary

Hoist make(map[...]...) calls out of for/range loops and clear the map each iteration.

org.openrewrite.golang.codequality.AllocateMapOutsideLoop
mod run . --recipe=org.openrewrite.golang.codequality.AllocateMapOutsideLoop

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.