Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestRaceAddrExpr (0.11 sec)

  1. src/runtime/race/testdata/mop_test.go

    		x = 42
    		c <- true
    	}()
    	_ = &x
    	<-c
    }
    
    type AddrT struct {
    	_ [256]byte
    	x int
    }
    
    type AddrT2 struct {
    	_ [512]byte
    	p *AddrT
    }
    
    func TestRaceAddrExpr(t *testing.T) {
    	c := make(chan bool, 1)
    	a := AddrT2{p: &AddrT{x: 42}}
    	go func() {
    		a.p = &AddrT{x: 43}
    		c <- true
    	}()
    	_ = &a.p.x
    	<-c
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 23 16:46:25 UTC 2023
    - 28.9K bytes
    - Viewed (0)
Back to top