Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for byteSliceArithmeticUint16 (0.3 sec)

  1. src/internal/fuzz/mutators_byteslice_test.go

    		{
    			name:     "byteSliceArithmeticUint8",
    			mutator:  byteSliceArithmeticUint8,
    			input:    []byte{1, 2, 3, 4},
    			expected: []byte{255, 2, 3, 4},
    		},
    		{
    			name:     "byteSliceArithmeticUint16",
    			mutator:  byteSliceArithmeticUint16,
    			input:    []byte{1, 2, 3, 4},
    			expected: []byte{1, 3, 3, 4},
    		},
    		{
    			name:     "byteSliceArithmeticUint32",
    			mutator:  byteSliceArithmeticUint32,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Nov 19 18:23:43 UTC 2021
    - 4.3K bytes
    - Viewed (0)
  2. src/internal/fuzz/mutators_byteslice.go

    	}
    	pos := m.rand(len(b))
    	v := byte(m.rand(35) + 1)
    	if m.r.bool() {
    		b[pos] += v
    	} else {
    		b[pos] -= v
    	}
    	return b
    }
    
    // byteSliceArithmeticUint16 adds/subtracts from a random uint16 in b.
    func byteSliceArithmeticUint16(m *mutator, b []byte) []byte {
    	if len(b) < 2 {
    		return nil
    	}
    	v := uint16(m.rand(35) + 1)
    	if m.r.bool() {
    		v = 0 - v
    	}
    	pos := m.rand(len(b) - 1)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Nov 19 18:23:43 UTC 2021
    - 7.7K bytes
    - Viewed (0)
  3. src/internal/fuzz/mutator.go

    	byteSliceRemoveBytes,
    	byteSliceInsertRandomBytes,
    	byteSliceDuplicateBytes,
    	byteSliceOverwriteBytes,
    	byteSliceBitFlip,
    	byteSliceXORByte,
    	byteSliceSwapByte,
    	byteSliceArithmeticUint8,
    	byteSliceArithmeticUint16,
    	byteSliceArithmeticUint32,
    	byteSliceArithmeticUint64,
    	byteSliceOverwriteInterestingUint8,
    	byteSliceOverwriteInterestingUint16,
    	byteSliceOverwriteInterestingUint32,
    	byteSliceInsertConstantBytes,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Sep 18 20:01:34 UTC 2023
    - 6.6K bytes
    - Viewed (0)
Back to top