cmd/vet: lock copy warning and unsafe.Offsetof #52700
Labels
Analysis
Issues related to static analysis (vet, x/tools/go/analysis)
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone
go 1.18.1
This may not be a bug but it was not obvious to me how to avoid the warning.
Consider the following situation:
This now triggers a warning with go vet: "call of unsafe.Offsetof copies lock value: B".
Clearly:
Offsetof
usageOffsetof
should be modified somehow to avoid triggering the warningThe text was updated successfully, but these errors were encountered: