Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestEqualNearPageBoundary (0.25 sec)

  1. src/bytes/boundary_test.go

    	}
    	err = syscall.Mprotect(b[2*pagesize:], syscall.PROT_NONE)
    	if err != nil {
    		t.Fatalf("mprotect high failed %s\n", err)
    	}
    	return b[pagesize : 2*pagesize]
    }
    
    func TestEqualNearPageBoundary(t *testing.T) {
    	t.Parallel()
    	b := dangerousSlice(t)
    	for i := range b {
    		b[i] = 'A'
    	}
    	for i := 0; i <= len(b); i++ {
    		Equal(b[:i], b[len(b)-i:])
    		Equal(b[len(b)-i:], b[:i])
    	}
    }
    
    Registered: Tue Oct 29 11:13:09 UTC 2024
    - Last Modified: Thu Nov 30 20:05:58 UTC 2023
    - 2.8K bytes
    - Viewed (0)
Back to top