Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for idx (0.12 sec)

  1. src/bytes/boundary_test.go

    		for i := range b {
    			idx := Index(b[i:], q[:j])
    			if idx != -1 {
    				t.Fatalf("Index(b[%d:], q[:%d])=%d, want -1\n", i, j, idx)
    			}
    		}
    		q[j-1] = 0
    	}
    
    	// Test differing alignments and sizes of q which always end on a page boundary.
    	q[len(q)-1] = 1 // difference is only found on the last byte
    	for j := 0; j < len(q); j++ {
    		for i := range b {
    			idx := Index(b[i:], q[j:])
    			if idx != -1 {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Nov 30 20:05:58 GMT 2023
    - 2.8K bytes
    - Viewed (0)
  2. src/archive/zip/reader.go

    			if name == "" {
    				continue
    			}
    
    			if idx, ok := files[name]; ok {
    				r.fileList[idx].isDup = true
    				continue
    			}
    			if idx, ok := knownDirs[name]; ok {
    				r.fileList[idx].isDup = true
    				continue
    			}
    
    			for dir := path.Dir(name); dir != "."; dir = path.Dir(dir) {
    				dirs[dir] = true
    			}
    
    			idx := len(r.fileList)
    			entry := fileListEntry{
    				name:  name,
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Oct 13 18:36:46 GMT 2023
    - 27.7K bytes
    - Viewed (0)
  3. src/archive/zip/writer_test.go

    		t.Fatal(err)
    	}
    	b := buf.Bytes()
    
    	var sig [4]byte
    	binary.LittleEndian.PutUint32(sig[:], uint32(fileHeaderSignature))
    
    	idx := bytes.Index(b, sig[:])
    	if idx == -1 {
    		t.Fatal("file header not found")
    	}
    	b = b[idx:]
    
    	if !bytes.Equal(b[6:10], []byte{0, 0, 0, 0}) { // FileHeader.Flags: 0, FileHeader.Method: 0
    		t.Errorf("unexpected method and flags: %v", b[6:10])
    	}
    
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Sep 15 19:04:06 GMT 2023
    - 14.1K bytes
    - Viewed (0)
Back to top