Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for tmp (0.14 sec)

  1. src/bytes/buffer_test.go

    func TestNext(t *testing.T) {
    	b := []byte{0, 1, 2, 3, 4}
    	tmp := make([]byte, 5)
    	for i := 0; i <= 5; i++ {
    		for j := i; j <= 5; j++ {
    			for k := 0; k <= 6; k++ {
    				// 0 <= i <= j <= 5; 0 <= k <= 6
    				// Check that if we start with a buffer
    				// of length j at offset i and ask for
    				// Next(k), we get the right bytes.
    				buf := NewBuffer(b[0:j])
    				n, _ := buf.Read(tmp[0:i])
    				if n != i {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Apr 26 13:31:36 GMT 2024
    - 18.6K bytes
    - Viewed (0)
  2. doc/go_spec.html

    element index plus one. A slice literal has the form
    </p>
    
    <pre>
    []T{x1, x2, … xn}
    </pre>
    
    <p>
    and is shorthand for a slice operation applied to an array:
    </p>
    
    <pre>
    tmp := [n]T{x1, x2, … xn}
    tmp[0 : n]
    </pre>
    
    <p>
    Within a composite literal of array, slice, or map type <code>T</code>,
    elements or map keys that are themselves composite literals may elide the respective
    HTML
    - Registered: Tue May 07 11:14:38 GMT 2024
    - Last Modified: Thu May 02 22:43:51 GMT 2024
    - 279.6K bytes
    - Viewed (0)
Back to top