Documentation ¶
Overview ¶
Package checklocks performs lock analysis to identify and flag unprotected access to annotated fields.
For detailed usage refer to README.md in the same directory.
Note that this package uses the built-in atomics, in order to avoid the use of our own atomic package. This is because our own atomic package depends on our own sync package, which includes lock dependency analysis. This in turn requires goid, which introduces a dependency cycle. To avoid this, we simply use the simpler, built-in sync package.
+checkalignedignore
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Analyzer = &analysis.Analyzer{ Name: "checklocks", Doc: "checks lock preconditions on functions and fields", Run: run, Requires: []*analysis.Analyzer{buildssa.Analyzer}, FactTypes: []analysis.Fact{ (*atomicAlignment)(nil), (*lockGuardFacts)(nil), (*lockFunctionFacts)(nil), }, }
Analyzer is the main entrypoint.
Functions ¶
This section is empty.
Types ¶
This section is empty.
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
cmd
|
|
checklocks
Binary checklocks is a `vettool` for `go vet`.
|
Binary checklocks is a `vettool` for `go vet`. |
Click to show internal directories.
Click to hide internal directories.