Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for testSliceGetElement (0.21 sec)

  1. src/cmd/compile/internal/test/testdata/array_test.go

    		}
    	}
    }
    
    //go:noinline
    func testSliceGetElement_ssa(a [10]int, i, j, p int) int {
    	return a[i:j][p]
    }
    
    func testSliceGetElement(t *testing.T) {
    	a := [10]int{0, 10, 20, 30, 40, 50, 60, 70, 80, 90}
    	tests := [...]struct {
    		i, j, p int
    		want    int // a[i:j][p]
    	}{
    		{0, 10, 2, 20},
    		{0, 5, 4, 40},
    		{5, 10, 3, 80},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Dec 23 06:40:04 UTC 2020
    - 3.1K bytes
    - Viewed (0)
Back to top