Skip to content

Commit 529ae97

Browse files
authored
Merge pull request #4703 from nojnhuh/no-prealloc
skip prealloc linter
2 parents 5d02f11 + 3b4e914 commit 529ae97

File tree

2 files changed

+0
-3
lines changed

2 files changed

+0
-3
lines changed

.golangci.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ linters:
4242
- noctx
4343
- nolintlint
4444
- nosprintfhostport
45-
- prealloc
4645
- predeclared
4746
- reassign
4847
- revive

azure/services/subnets/spec.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,6 @@ func (s *SubnetSpec) Parameters(ctx context.Context, existing *asonetworkv1.Virt
9797
}
9898
}
9999

100-
//nolint:prealloc // pre-allocating this slice isn't going to make any meaningful performance difference
101-
// and makes it harder to keep this value nil when s.ServiceEndpoints is empty as is necessary.
102100
var serviceEndpoints []asonetworkv1.ServiceEndpointPropertiesFormat
103101
for _, se := range s.ServiceEndpoints {
104102
serviceEndpoints = append(serviceEndpoints, asonetworkv1.ServiceEndpointPropertiesFormat{Service: ptr.To(se.Service), Locations: se.Locations})

0 commit comments

Comments
 (0)