MCPcopy
hub / github.com/google/gvisor / testInconsistentReturn

Function testInconsistentReturn

tools/checklocks/test/branches.go:21–25  ·  view source on GitHub ↗
(tc *oneGuardStruct)

Source from the content-addressed store, hash-verified

19)
20
21func testInconsistentReturn(tc *oneGuardStruct) { // +checklocksfail
22 if x := rand.Intn(10); x%2 == 1 {
23 tc.mu.Lock()
24 }
25}
26
27func testConsistentBranching(tc *oneGuardStruct) {
28 x := rand.Intn(10)

Callers

nothing calls this directly

Calls 1

LockMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…